Updated on 2026-08-14

This commit is contained in:
Tangem 2025-10-16 12:17:45 +03:00
parent c562c3fbba
commit 8968f1822a
10 changed files with 146 additions and 7 deletions

View file

@ -121,6 +121,10 @@ internal class WalletSettingsModel @Inject constructor(
}
init {
getUserWalletUseCase.invoke(params.userWalletId).onRight {
analyticsContextProxy.addContext(it)
}
fun combineUI(wallet: UserWallet) = combine(
getWalletNFTEnabledUseCase.invoke(params.userWalletId),
getWalletNotificationsEnabledUseCase(params.userWalletId),
@ -155,6 +159,11 @@ internal class WalletSettingsModel @Inject constructor(
.launchIn(modelScope)
}
override fun onDestroy() {
super.onDestroy()
analyticsContextProxy.removeContext()
}
private fun isNotificationsPermissionGranted(): Boolean {
return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
permissionsRepository.hasRuntimePermission(