Updated on 2026-08-14

This commit is contained in:
Tangem 2024-11-26 13:17:34 +04:00
parent 207da4af08
commit 7aef4046c3
31 changed files with 238 additions and 91 deletions

View file

@ -387,10 +387,6 @@ fun Blockchain.toMigratedCointId(): String = when (this) {
else -> toCoinId()
}
fun Blockchain.isSupportedInApp(): Boolean {
return !excludedBlockchains.contains(this)
}
fun Blockchain.amountToCreateAccount(token: Token? = null): BigDecimal? {
return when (this) {
Blockchain.Stellar -> if (token?.symbol == NODL) BigDecimal(NODL_AMOUNT_TO_CREATE_ACCOUNT) else BigDecimal.ONE
@ -409,11 +405,4 @@ fun Blockchain.minimalAmount(): BigDecimal {
}
private const val NODL = "NODL"
private const val NODL_AMOUNT_TO_CREATE_ACCOUNT = 1.5
// no need to add testnets
private val excludedBlockchains = listOf(
Blockchain.Unknown,
Blockchain.Nexa,
Blockchain.NexaTestnet,
)
private const val NODL_AMOUNT_TO_CREATE_ACCOUNT = 1.5