Updated on 2026-08-14
This commit is contained in:
parent
fabd706b12
commit
8f4e5ed3e0
2 changed files with 13 additions and 15 deletions
|
|
@ -27,8 +27,8 @@ enum class ExpressProviderType(val typeName: String) {
|
|||
fun ExpressProviderType.shouldStoreSwapTransaction() = when (this) {
|
||||
CEX,
|
||||
DEX_BRIDGE,
|
||||
-> true
|
||||
DEX,
|
||||
-> true
|
||||
ONRAMP,
|
||||
-> false
|
||||
}
|
||||
|
|
|
|||
|
|
@ -904,19 +904,17 @@ internal class SwapInteractorImpl @AssistedInject constructor(
|
|||
txHash = txHash,
|
||||
payInExtraId = swapData.transaction.txExtraId,
|
||||
)
|
||||
if (provider.type == ExchangeProviderType.DEX_BRIDGE) {
|
||||
val timestamp = System.currentTimeMillis()
|
||||
storeSwapTransaction(
|
||||
currencyToSend = currencyToSendStatus,
|
||||
currencyToGet = currencyToGetStatus,
|
||||
fromAccount = fromAccount,
|
||||
toAccount = toAccount,
|
||||
amount = amount,
|
||||
swapProvider = provider,
|
||||
swapDataModel = swapData,
|
||||
timestamp = timestamp,
|
||||
)
|
||||
}
|
||||
val timestamp = System.currentTimeMillis()
|
||||
storeSwapTransaction(
|
||||
currencyToSend = currencyToSendStatus,
|
||||
currencyToGet = currencyToGetStatus,
|
||||
fromAccount = fromAccount,
|
||||
toAccount = toAccount,
|
||||
amount = amount,
|
||||
swapProvider = provider,
|
||||
swapDataModel = swapData,
|
||||
timestamp = timestamp,
|
||||
)
|
||||
storeLastCryptoCurrencyId(currencyToGetStatus.currency)
|
||||
SwapTransactionState.TxSent(
|
||||
fromAmount = amountFormatter.formatSwapAmountToUI(
|
||||
|
|
@ -930,7 +928,7 @@ internal class SwapInteractorImpl @AssistedInject constructor(
|
|||
),
|
||||
toAmountValue = swapData.toTokenAmount.value,
|
||||
txHash = txHash,
|
||||
timestamp = System.currentTimeMillis(),
|
||||
timestamp = timestamp,
|
||||
)
|
||||
},
|
||||
ifLeft = { SwapTransactionState.Error.TransactionError(it) },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue