Skip to content

Commit

Permalink
Remove unnecessary conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
pcw109550 committed Nov 6, 2023
1 parent 699ca44 commit 3e319d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/rpcdaemon/commands/otterscan_api.go
Original file line number Diff line number Diff line change
Expand Up @@ -523,8 +523,8 @@ func (api *OtterscanAPIImpl) searchTransactionsBeforeV3(tx kv.TemporalTx, ctx co
var receipt *types.Receipt
if chainConfig.IsOptimism() {
receipts := rawdb.ReadRawReceipts(tx, blockNum)
if len(receipts) <= int(txIndex) {
return nil, fmt.Errorf("block has less receipts than expected: %d <= %d, block: %d", len(receipts), int(txIndex), blockNum)
if len(receipts) <= txIndex {
return nil, fmt.Errorf("block has less receipts than expected: %d <= %d, block: %d", len(receipts), txIndex, blockNum)
}
receipt = receipts[txIndex]
}
Expand Down

0 comments on commit 3e319d2

Please sign in to comment.