Updated on 2026-08-14
This commit is contained in:
parent
aed32a47f1
commit
58e26ca5e6
8 changed files with 139 additions and 14 deletions
|
|
@ -42,6 +42,7 @@ import com.tangem.datasource.local.logs.AppLogsStore
|
|||
import com.tangem.datasource.local.preferences.AppPreferencesStore
|
||||
import com.tangem.datasource.local.token.UserTokensResponseStore
|
||||
import com.tangem.datasource.utils.NetworkLogsSaveInterceptor
|
||||
import com.tangem.datasource.utils.WireMockRedirectInterceptor
|
||||
import com.tangem.domain.appcurrency.repository.AppCurrencyRepository
|
||||
import com.tangem.domain.apptheme.GetAppThemeModeUseCase
|
||||
import com.tangem.domain.apptheme.repository.AppThemeModeRepository
|
||||
|
|
@ -334,15 +335,23 @@ open class TangemApplication : Application(), ImageLoaderFactory, Configuration.
|
|||
ExceptionHandler.append(blockchainExceptionHandler)
|
||||
|
||||
if (LogConfig.network.isBlockchainSdkNetworkLogEnabled) {
|
||||
BlockchainSdkRetrofitBuilder.interceptors = listOf(
|
||||
createNetworkLoggingInterceptor(),
|
||||
ChuckerInterceptor(this),
|
||||
)
|
||||
BlockchainSdkRetrofitBuilder.interceptors = buildList {
|
||||
if (BuildConfig.MOCK_DATA_SOURCE) {
|
||||
add(WireMockRedirectInterceptor())
|
||||
}
|
||||
add(createNetworkLoggingInterceptor())
|
||||
add(ChuckerInterceptor(this@TangemApplication))
|
||||
}
|
||||
|
||||
TangemApiServiceSettings.addInterceptors(
|
||||
createNetworkLoggingInterceptor(),
|
||||
ChuckerInterceptor(this),
|
||||
NetworkLogsSaveInterceptor(appLogsStore),
|
||||
*buildList {
|
||||
if (BuildConfig.MOCK_DATA_SOURCE) {
|
||||
add(WireMockRedirectInterceptor())
|
||||
}
|
||||
add(createNetworkLoggingInterceptor())
|
||||
add(ChuckerInterceptor(this@TangemApplication))
|
||||
add(NetworkLogsSaveInterceptor(appLogsStore))
|
||||
}.toTypedArray(),
|
||||
)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue