Skip to content

Commit

Permalink
RPCdaemon: fix to work also with snapshot (#8111)
Browse files Browse the repository at this point in the history
The FIX is necessary to permit to use API also in case block is in the
snapshot files
  • Loading branch information
lupin012 authored Sep 2, 2023
1 parent 42101f5 commit 5a9f430
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion turbo/jsonrpc/eth_block.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ func (api *APIImpl) CallBundle(ctx context.Context, txHashes []common.Hash, stat
}
ibs := state.New(stateReader)

parent := rawdb.ReadHeader(tx, hash, stateBlockNumber)
parent, _ := api.headerByRPCNumber(rpc.BlockNumber(stateBlockNumber), tx)
if parent == nil {
return nil, fmt.Errorf("block %d(%x) not found", stateBlockNumber, hash)
}
Expand Down

0 comments on commit 5a9f430

Please sign in to comment.