Skip to content

Commit

Permalink
Use a new 50mil gas meter instead of infinite
Browse files Browse the repository at this point in the history
  • Loading branch information
NotJeremyLiu committed Jul 17, 2023
1 parent 0070c5a commit 5789614
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions x/protorev/keeper/posthandler.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ func (protoRevDec ProtoRevDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simu
}

// Delete swaps to backrun for next transaction without consuming gas
// from the current transaction's gas meter, but instead from an infinite gas meter.
protoRevDec.ProtoRevKeeper.DeleteSwapsToBackrun(ctx.WithGasMeter(sdk.NewInfiniteGasMeter()))
// from the current transaction's gas meter, but instead from a new gas meter with 50mil gas.
protoRevDec.ProtoRevKeeper.DeleteSwapsToBackrun(ctx.WithGasMeter(sdk.NewGasMeter(sdk.Gas(50_000_000))))

return next(ctx, tx, simulate)
}
Expand Down

0 comments on commit 5789614

Please sign in to comment.