Updated on 2026-08-14

This commit is contained in:
Tangem 2023-05-31 18:22:10 +03:00
parent c8acba2f3b
commit cc4b2e8299

View file

@ -279,33 +279,20 @@ class TransactionManagerImpl(
return when (fee) {
is Result.Success -> {
val choosableFee = fee.data
ProxyFees(
minFee = ProxyFee(
gasLimit = walletManager.gasLimit ?: BigInteger.ZERO,
fee = convertToProxyAmount(choosableFee.minimum),
),
normalFee = ProxyFee(
gasLimit = BigInteger.ZERO,
fee = convertToProxyAmount(amount = choosableFee.normal),
),
priorityFee = ProxyFee(
gasLimit = BigInteger.ZERO,
fee = convertToProxyAmount(amount = choosableFee.priority),
)
)
val minProxyFee = ProxyFee(
gasLimit = walletManager.gasLimit ?: BigInteger.ZERO,
fee = convertToProxyAmount(fee.data.minimum),
fee = convertToProxyAmount(amount = choosableFee.minimum),
)
val normalProxyFee = ProxyFee(
gasLimit = walletManager.gasLimit ?: BigInteger.ZERO,
fee = convertToProxyAmount(fee.data.normal),
fee = convertToProxyAmount(amount = choosableFee.normal),
)
val priorityProxyFee = ProxyFee(
gasLimit = walletManager.gasLimit ?: BigInteger.ZERO,
fee = convertToProxyAmount(fee.data.priority),
fee = convertToProxyAmount(amount = choosableFee.priority),
)
ProxyFees(
minFee = minProxyFee,
normalFee = normalProxyFee,