From 4834b82b5f6cf2f8ebfd229af906cbd898112710 Mon Sep 17 00:00:00 2001 From: Lyka Labrada Date: Wed, 1 Nov 2023 17:21:08 +0800 Subject: [PATCH] enable 'Coin Transsfer' transaction type --- src/shared/transactionDataHelper.ts | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/src/shared/transactionDataHelper.ts b/src/shared/transactionDataHelper.ts index 2cd9fdf6..08edb578 100644 --- a/src/shared/transactionDataHelper.ts +++ b/src/shared/transactionDataHelper.ts @@ -142,9 +142,9 @@ export const getTransactionType = ({ tokenTransfers?.length > 0 || (txTypes.includes(RawTransactionType.TokenTransfer) && !txTypes.includes(RawTransactionType.ContractCreation)); - // const involvesCoinTransfer = - // txTypes.includes(RawTransactionType.CoinTransfer) && - // !txTypes.includes(RawTransactionType.ContractCreation); + const involvesCoinTransfer = + txTypes.includes(RawTransactionType.CoinTransfer) && + !txTypes.includes(RawTransactionType.ContractCreation); const involvesContract = isFromContract || isToContract || createdContract; if (involvesTokenTransfers) { @@ -155,10 +155,9 @@ export const getTransactionType = ({ transactionType = TransactionType.ContractCall; } // Display Transaction as tx type for CoinTransfer - // else if (involvesCoinTransfer) { - // transactionType = TransactionType.CoinTransfer; - // } - else { + else if (involvesCoinTransfer) { + transactionType = TransactionType.CoinTransfer; + } else { transactionType = TransactionType.Transaction; }