Skip to content

Commit

Permalink
add explanatory comment
Browse files Browse the repository at this point in the history
  • Loading branch information
sviderock committed Oct 16, 2024
1 parent 5944819 commit e2cf8ff
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/transactions/feed/TransactionFeedV2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,11 @@ function useStandByTransactions() {
}, [standByTransactions, allowedNetworkForTransfers])
}

/**
* In order to properly detect if any of the existing pending transactions turned into completed
* we need to listen to the updates of stand by transactions. Whenever we detect that a confirmed
* transaction was in pending status on previous render - we consider it a newly completed transaction.
*/
function useNewlyCompletedTransactions(
standByTransactions: ReturnType<typeof useStandByTransactions>
) {
Expand Down

0 comments on commit e2cf8ff

Please sign in to comment.