diff --git a/src/plugins/usage_collection/server/collector/collector.ts b/src/plugins/usage_collection/server/collector/collector.ts index 4986e22ed90248..c04b087d4adf56 100644 --- a/src/plugins/usage_collection/server/collector/collector.ts +++ b/src/plugins/usage_collection/server/collector/collector.ts @@ -72,7 +72,7 @@ export interface CollectorOptions { type: string; init?: Function; /** - * Method to return `true`/`false` to confirm if the collector is ready for the `fetch` method to be called. + * Method to return `true`/`false` or Promise(`true`/`false`) to confirm if the collector is ready for the `fetch` method to be called. */ isReady: () => Promise | boolean; /** @@ -101,7 +101,7 @@ export class Collector { * @param {Function} options.init (optional) - initialization function * @param {Function} options.fetch - function to query data * @param {Function} options.formatForBulkUpload - optional - * @param {boolean} options.isReady - boolean to indicate collector is ready to report data + * @param {Function} options.isReady - method that returns a boolean or Promise of a boolean to indicate the collector is ready to report data * @param {Function} options.rest - optional other properties */ constructor(