(result)
| 129 | */ |
| 130 | setupInitialization () { |
| 131 | const finishInitialization = (result) => { |
| 132 | this.isInitialized = result |
| 133 | |
| 134 | // We only want to resolve / reject the init promise once during the initialization flow. Because some trackers |
| 135 | // do not support reporting "failures" we need to support timeouts that can result in race conditions in some |
| 136 | // situations. In these situations we use the first success / fail callback to determine the tracker state and |
| 137 | // we change the callbacks to noops to prevent later calls from changing the init state. |
| 138 | this.onInitializeSuccess = () => {} |
| 139 | this.onInitializeFail = () => {} |
| 140 | } |
| 141 | |
| 142 | this.initializationCompletePromise = new Promise((resolve, reject) => { |
| 143 | this.onInitializeSuccess = () => { |
nothing calls this directly
no outgoing calls
no test coverage detected