Skip to content
This repository has been archived by the owner on Apr 15, 2024. It is now read-only.

Commit

Permalink
feat: support sending EIP1559 transactions depending on the target chain
Browse files Browse the repository at this point in the history
  • Loading branch information
rach-id committed Dec 7, 2023
1 parent e7f399e commit 5023617
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions evm/evm_transaction_opts.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,9 @@ func newTransactOptsBuilder(ks *keystore.KeyStore, acc *accounts.Account) transa
return nil, fmt.Errorf("failed to create Ethereum transactor: %w", err)
}

bigGasPrice, err := client.SuggestGasPrice(ctx)
if err != nil {
return nil, fmt.Errorf("failed to get Ethereum gas estimate: %w", err)
}

auth.Nonce = new(big.Int).SetUint64(nonce)
auth.Value = big.NewInt(0) // in wei
auth.GasLimit = gasLim // in units
auth.GasPrice = bigGasPrice

return auth, nil
}
Expand Down

0 comments on commit 5023617

Please sign in to comment.