mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-16 21:16:37 +00:00
ethclient: fix BlockReceipts parameter encoding (#28087)
Co-authored-by: Felix Lange <fjl@twurst.com>
This commit is contained in:
parent
f6f64cc43d
commit
4985d83b8f
1 changed files with 2 additions and 2 deletions
|
|
@ -108,10 +108,10 @@ func (ec *Client) PeerCount(ctx context.Context) (uint64, error) {
|
||||||
return uint64(result), err
|
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) {
|
func (ec *Client) BlockReceipts(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) ([]*types.Receipt, error) {
|
||||||
var r []*types.Receipt
|
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 {
|
if err == nil && r == nil {
|
||||||
return nil, ethereum.NotFound
|
return nil, ethereum.NotFound
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue