Updated on 2026-08-14

This commit is contained in:
Tangem 2025-09-16 17:51:07 +03:00
parent 5c56f04c38
commit 9bd372d0af
6 changed files with 47 additions and 13 deletions

View file

@ -77,10 +77,16 @@ object BlockchainUtils {
return blockchain == Blockchain.TON || blockchain == Blockchain.TONTestnet
}
fun isSupportedNetworkId(blockchainId: String, excludedBlockchains: ExcludedBlockchains): Boolean {
fun isSupportedNetworkId(
blockchainId: String,
excludedBlockchains: ExcludedBlockchains,
hotExcludedBlockchains: Set<Blockchain>,
hasOnlyHotWallets: Boolean = false,
): Boolean {
val blockchain = Blockchain.fromNetworkId(blockchainId)
return blockchain != null && blockchain !in excludedBlockchains
return blockchain != null && blockchain !in excludedBlockchains &&
(hasOnlyHotWallets.not() || blockchain !in hotExcludedBlockchains)
}
fun isArbitrum(blockchainId: String): Boolean {