Updated on 2026-08-14

This commit is contained in:
Tangem 2025-10-03 10:59:01 +07:00
parent 8aba7b07d1
commit 57fc519d5f
3 changed files with 63 additions and 33 deletions

View file

@ -1,6 +1,7 @@
package com.tangem.domain.models.account
import com.tangem.domain.core.lce.Lce
import com.tangem.domain.models.currency.CryptoCurrencyStatus
import com.tangem.domain.models.quote.PriceChange
import com.tangem.domain.models.tokenlist.TokenList
import kotlinx.serialization.Serializable
@ -29,4 +30,8 @@ sealed interface AccountStatus {
val tokenList: TokenList,
val priceChangeLce: Lce<Unit, PriceChange>,
) : AccountStatus
fun flattenCurrencies(): List<CryptoCurrencyStatus> = when (this) {
is CryptoPortfolio -> tokenList.flattenCurrencies()
}
}