@@ -228,41 +228,16 @@ export const getIsInitCalled = (): boolean => !!getValueFromWindow(initFlagKey)?
228
228
*/
229
229
export const init = ( embedConfig : EmbedConfig ) : AuthEventEmitter => {
230
230
sanity ( embedConfig ) ;
231
- //resetAllCachedServices();
232
- /*embedConfig = setEmbedConfig(
233
- backwardCompat({
234
- ...CONFIG_DEFAULTS,
235
- ...embedConfig,
236
- thoughtSpotHost: getThoughtSpotHost(embedConfig),
237
- }),
238
- );
239
231
240
- setGlobalLogLevelOverride(embedConfig.logLevel);
241
- registerReportingObserver();
242
- */
243
232
const authEE = new EventEmitter < AuthStatus | AuthEvent > ( ) ;
244
233
setAuthEE ( authEE ) ;
245
- handleAuth ( ) ;
246
234
247
235
const { password, ...configToTrack } = getEmbedConfig ( ) ;
248
- /* uploadMixpanelEvent(MIXPANEL_EVENT.VISUAL_SDK_CALLED_INIT, {
249
- ...configToTrack,
250
- usedCustomizationSheet: embedConfig.customizations?.style?.customCSSUrl != null,
251
- usedCustomizationVariables: embedConfig.customizations?.style?.customCSS?.variables != null,
252
- usedCustomizationRules:
253
- embedConfig.customizations?.style?.customCSS?.rules_UNSTABLE != null,
254
- usedCustomizationStrings: !!embedConfig.customizations?.content?.strings,
255
- usedCustomizationIconSprite: !!embedConfig.customizations?.iconSpriteUrl,
256
- }); */
257
236
258
237
if ( getEmbedConfig ( ) . callPrefetch ) {
259
238
prefetch ( getEmbedConfig ( ) . thoughtSpotHost ) ;
260
239
}
261
240
262
- // Resolves the promise created in the initPromiseKey
263
- /*getValueFromWindow<InitFlagStore>(initFlagKey).initPromiseResolve(authEE);
264
- getValueFromWindow<InitFlagStore>(initFlagKey).isInitCalled = true; */
265
-
266
241
return authEE as AuthEventEmitter ;
267
242
} ;
268
243
0 commit comments