Skip to content

Commit

Permalink
dont save empty hash
Browse files Browse the repository at this point in the history
  • Loading branch information
nguyenhoaidanh committed Jul 20, 2023
1 parent 79450db commit 31272cc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/state/transactions/reducer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ export default createReducer(initialState, builder =>
) => {
const chainTxs = transactions[chainId] ?? {}
const txs = (firstTxHash && chainTxs[firstTxHash]) || []
if (txs.find(e => e.hash === hash)) {
// duplicate
if (!hash || txs.find(e => e.hash === hash)) {
// duplicate or not found hash
return
}
txs.push({
Expand Down

0 comments on commit 31272cc

Please sign in to comment.