mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-19 21:31:37 +00:00
accounts/abi/bind: add const for tx fee elasticity multiplier (#25504)
Co-authored-by: Felix Lange <fjl@twurst.com> Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
This commit is contained in:
parent
aec9d767cc
commit
bdf80d77e4
1 changed files with 3 additions and 1 deletions
|
|
@ -36,6 +36,8 @@ var (
|
|||
errNoEventSignature = errors.New("no event signature")
|
||||
)
|
||||
|
||||
const basefeeWiggleMultiplier = 2
|
||||
|
||||
// SignerFn is a signer function callback when a contract requires a method to
|
||||
// sign the transaction before submission.
|
||||
type SignerFn func(common.Address, *types.Transaction) (*types.Transaction, error)
|
||||
|
|
@ -258,7 +260,7 @@ func (c *BoundContract) createDynamicTx(opts *TransactOpts, contract *common.Add
|
|||
if gasFeeCap == nil {
|
||||
gasFeeCap = new(big.Int).Add(
|
||||
gasTipCap,
|
||||
new(big.Int).Mul(head.BaseFee, big.NewInt(2)),
|
||||
new(big.Int).Mul(head.BaseFee, big.NewInt(basefeeWiggleMultiplier)),
|
||||
)
|
||||
}
|
||||
if gasFeeCap.Cmp(gasTipCap) < 0 {
|
||||
|
|
|
|||
Loading…
Reference in a new issue