Updated on 2026-08-14

This commit is contained in:
Tangem 2023-04-07 20:39:24 +08:00
parent 069605e151
commit 36516c900f
234 changed files with 902 additions and 1618 deletions

View file

@ -42,7 +42,9 @@ class DerivationManagerImpl(
contractAddress = currency.contractAddress,
decimals = currency.decimalCount,
)
} else null
} else {
null
}
val blockchainNetwork = BlockchainNetwork(blockchain, card)
val appCurrency = com.tangem.tap.features.wallet.models.Currency.fromBlockchainNetwork(
blockchainNetwork,

View file

@ -397,11 +397,7 @@ class TransactionManagerImpl(
}
}
private fun createAmount(
amount: BigDecimal,
currency: Currency,
blockchain: Blockchain,
): Amount {
private fun createAmount(amount: BigDecimal, currency: Currency, blockchain: Blockchain): Amount {
return when (currency) {
is Currency.NativeToken -> {
Amount(value = amount, blockchain = blockchain)
@ -412,11 +408,7 @@ class TransactionManagerImpl(
}
}
private fun createAmountForSwap(
amount: BigDecimal,
currency: Currency?,
blockchain: Blockchain,
): Amount {
private fun createAmountForSwap(amount: BigDecimal, currency: Currency?, blockchain: Blockchain): Amount {
return when (currency) {
is Currency.NativeToken,
null,