Updated on 2026-08-14

This commit is contained in:
Tangem 2025-09-15 19:11:08 +05:00
parent a258763b81
commit 6d3a1d6e89

View file

@ -277,7 +277,7 @@ internal class GetMultiWalletWarningsFactory @Inject constructor(
) {
addIf(
element = WalletNotification.Warning.YeildSupplyApprove,
condition = tokenList.hasNetworksWithLendingsWithoutApprove(),
condition = tokenList.hasTokensWithActivatedSupplyWithoutApprove(),
)
}
@ -311,7 +311,7 @@ internal class GetMultiWalletWarningsFactory @Inject constructor(
return tokenList.flattenCurrencies().any { it.value is CryptoCurrencyStatus.Unreachable }
}
private fun Lce<TokenListError, TokenList>.hasNetworksWithLendingsWithoutApprove(): Boolean {
private fun Lce<TokenListError, TokenList>.hasTokensWithActivatedSupplyWithoutApprove(): Boolean {
val tokenList = getOrNull(isPartialContentAccepted = false) ?: return false
val yieldSupplyEnabled = yieldSupplyFeatureToggles.isYieldSupplyFeatureEnabled
return yieldSupplyEnabled && tokenList.flattenCurrencies().any {