Updated on 2026-08-14

This commit is contained in:
Tangem 2022-09-15 20:16:47 +03:00
parent 30d2fab208
commit bdf6a18a02
2 changed files with 7 additions and 17 deletions

View file

@ -66,11 +66,7 @@ class TapApplication : Application(), ImageLoaderFactory {
walletConnectRepository = WalletConnectRepository(this)
val configLoader = FeaturesLocalLoader(AndroidAssetReader(this), MoshiConverter.defaultMoshi())
initConfigManager(configLoader) { config ->
shopService = TangemShopService(this, config.shopify!!)
initAppsFlyer(this, config)
initFeedbackManager(this, preferencesStorage, config)
}
initConfigManager(configLoader, ::initWithConfigDependency)
initWarningMessagesManager()
BlockchainSdkRetrofitBuilder.enableNetworkLogging = BuildConfig.DEBUG
@ -88,6 +84,12 @@ class TapApplication : Application(), ImageLoaderFactory {
}
}
private fun initWithConfigDependency(config: Config) {
shopService = TangemShopService(this, config.shopify!!)
initAppsFlyer(this, config)
initFeedbackManager(this, preferencesStorage, config)
}
private fun initAppsFlyer(context: Context, config: Config) {
AppsFlyerLib.getInstance().init(config.appsFlyerDevKey, null, context)
AppsFlyerLib.getInstance().start(context)