Skip to content

Commit

Permalink
Don't double fetch header in DoEstimateGas
Browse files Browse the repository at this point in the history
  • Loading branch information
PlasmaPower committed Jun 20, 2024
1 parent ed3aa85 commit 2b48be8
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions internal/ethapi/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -1279,10 +1279,6 @@ func DoEstimateGas(ctx context.Context, b Backend, args TransactionArgs, blockNr

// Arbitrum: raise the gas cap to ignore L1 costs so that it's compute-only
{
state, header, err := b.StateAndHeaderByNumberOrHash(ctx, blockNrOrHash)
if state == nil || err != nil {
return 0, err
}
gasCap, err = args.L2OnlyGasCap(gasCap, header, state, core.MessageGasEstimationMode)
if err != nil {
return 0, err
Expand Down

0 comments on commit 2b48be8

Please sign in to comment.