Update ethclient/ethclient.go

This commit is contained in:
Martin HS 2023-12-30 17:09:43 +01:00 committed by GitHub
parent c4bff96840
commit 853b07af34
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -306,8 +306,7 @@ func (ec *Client) TransactionInBlock(ctx context.Context, blockHash common.Hash,
// Note that the receipt is not available for pending transactions. // Note that the receipt is not available for pending transactions.
func (ec *Client) TransactionReceipt(ctx context.Context, txHash common.Hash) (*types.Receipt, error) { func (ec *Client) TransactionReceipt(ctx context.Context, txHash common.Hash) (*types.Receipt, error) {
var r *types.Receipt var r *types.Receipt
err := ec.c.CallContext(ctx, &r, "eth_getTransactionReceipt", txHash) if err := ec.c.CallContext(ctx, &r, "eth_getTransactionReceipt", txHash); err != nil {
if err != nil {
return nil, err return nil, err
} }
if r == nil { if r == nil {