Skip to content

Commit

Permalink
Fix index increment in block tracing
Browse files Browse the repository at this point in the history
  • Loading branch information
hkalodner committed Jun 2, 2022
1 parent d71a261 commit 9180527
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/arb-rpc-node/web3/trace.go
Original file line number Diff line number Diff line change
Expand Up @@ -436,6 +436,7 @@ func (t *Trace) block(ctx context.Context, blockNum rpc.BlockNumberOrHash, trace
for i := uint64(0); i < blockLog.BlockStats.TxCount.Uint64(); i++ {
txRes := txResults[i]
txTrace, err := t.traceTransaction(ctx, cursor, txRes, logIndex, traceDestroyed)
logIndex.Add(logIndex, big.NewInt(1))
if err != nil {
logger.
Warn().
Expand All @@ -446,7 +447,6 @@ func (t *Trace) block(ctx context.Context, blockNum rpc.BlockNumberOrHash, trace
continue
}
res = append(res, txTrace)
logIndex.Add(logIndex, big.NewInt(1))
}
return res, blockInfo, cursor, nil
}
Expand Down

0 comments on commit 9180527

Please sign in to comment.