Skip to content

Commit

Permalink
ethclient: fix BlockReceipts parameter encoding (ethereum#28087)
Browse files Browse the repository at this point in the history
Co-authored-by: Felix Lange <fjl@twurst.com>
  • Loading branch information
2 people authored and devopsbo3 committed Nov 10, 2023
1 parent 877c5be commit 2e3ba71
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ethclient/ethclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,10 @@ func (ec *Client) PeerCount(ctx context.Context) (uint64, error) {
return uint64(result), err
}

// BlockReceipts returns the receipts of a given block number or hash
// BlockReceipts returns the receipts of a given block number or hash.
func (ec *Client) BlockReceipts(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) ([]*types.Receipt, error) {
var r []*types.Receipt
err := ec.c.CallContext(ctx, &r, "eth_getBlockReceipts", blockNrOrHash)
err := ec.c.CallContext(ctx, &r, "eth_getBlockReceipts", blockNrOrHash.String())
if err == nil && r == nil {
return nil, ethereum.NotFound
}
Expand Down

0 comments on commit 2e3ba71

Please sign in to comment.