Removes some leftover `err` check (#29339)

Before, `ToMessage` was returning both the resulting `Message` and an error while no error is returned now.

Those error checks were probably leftover from the past.
pull/29344/head
Matthieu Vachon 8 months ago committed by GitHub
parent 100c0f47de
commit 738b5a586e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 6
      internal/ethapi/api.go

@ -1186,9 +1186,6 @@ func DoEstimateGas(ctx context.Context, b Backend, args TransactionArgs, blockNr
return 0, err
}
call := args.ToMessage(header.BaseFee)
if err != nil {
return 0, err
}
// Run the gas estimation andwrap any revertals into a custom return
estimate, revert, err := gasestimator.Estimate(ctx, call, opts, gasCap)
if err != nil {
@ -1519,9 +1516,6 @@ func AccessList(ctx context.Context, b Backend, blockNrOrHash rpc.BlockNumberOrH
// Set the accesslist to the last al
args.AccessList = &accessList
msg := args.ToMessage(header.BaseFee)
if err != nil {
return nil, 0, nil, err
}
// Apply the transaction with the access list tracer
tracer := logger.NewAccessListTracer(accessList, args.from(), to, precompiles)

Loading…
Cancel
Save