@@ -1285,27 +1285,22 @@ export default class Optimizely extends BaseService implements Client {
1285
1285
1286
1286
/**
1287
1287
* Returns a Promise that fulfills when this instance is ready to use (meaning
1288
- * it has a valid datafile), or has failed to become ready within a period of
1288
+ * it has a valid datafile), or rejects when it has failed to become ready within a period of
1289
1289
* time (configurable by the timeout property of the options argument), or when
1290
- * this instance is closed via the close method.
1290
+ * this instance is closed via the close method before it became ready .
1291
1291
*
1292
- * If a valid datafile was provided in the constructor, the returned Promise is
1293
- * immediately fulfilled. If an sdkKey was provided, a manager will be used to
1294
- * fetch a datafile, and the returned promise will fulfill if that fetch
1295
- * succeeds or fails before the timeout. The default timeout is 30 seconds,
1296
- * which will be used if no timeout is provided in the argument options object .
1292
+ * If a static project config manager with a valid datafile was provided in the constructor,
1293
+ * the returned Promise is immediately fulfilled. If a polling config manager was provided,
1294
+ * it will be used to fetch a datafile, and the returned promise will fulfill if that fetch
1295
+ * succeeds, or it will reject if the datafile fetch does not complete before the timeout.
1296
+ * The default timeout is 30 seconds .
1297
1297
*
1298
- * The returned Promise is fulfilled with a result object containing these
1299
- * properties:
1300
- * - success (boolean): True if this instance is ready to use with a valid
1301
- * datafile, or false if this instance failed to become
1302
- * ready or was closed prior to becoming ready.
1303
- * - reason (string=): If success is false, this is a string property with
1304
- * an explanatory message. Failure could be due to
1305
- * expiration of the timeout, network errors,
1306
- * unsuccessful responses, datafile parse errors,
1307
- * datafile validation errors, or the instance being
1308
- * closed
1298
+ * The returned Promise is fulfilled with an unknown result which is not needed to
1299
+ * be inspect to know that the instance is ready. If the promise is fulfilled, it
1300
+ * is guaranteed that the instance is ready to use. If the promise is rejected, it
1301
+ * means the instance is not ready to use, and the reason for the promise rejection
1302
+ * will contain an error denoting the cause of failure.
1303
+
1309
1304
* @param {Object= } options
1310
1305
* @param {number|undefined } options.timeout
1311
1306
* @return {Promise }
0 commit comments