@@ -1607,7 +1607,7 @@ func (api *TransactionAPI) SendTransaction(ctx context.Context, args Transaction
16071607 return common.Hash {}, err
16081608 }
16091609 // Assemble the transaction and sign with the wallet
1610- tx := args .ToTransaction (types .LegacyTxType )
1610+ tx := args .ToTransaction (types .DynamicFeeTxType )
16111611
16121612 signed , err := wallet .SignTx (account , tx , api .b .ChainConfig ().ChainID )
16131613 if err != nil {
@@ -1629,7 +1629,7 @@ func (api *TransactionAPI) FillTransaction(ctx context.Context, args Transaction
16291629 return nil , err
16301630 }
16311631 // Assemble the transaction and obtain rlp
1632- tx := args .ToTransaction (types .LegacyTxType )
1632+ tx := args .ToTransaction (types .DynamicFeeTxType )
16331633 data , err := tx .MarshalBinary ()
16341634 if err != nil {
16351635 return nil , err
@@ -1825,7 +1825,7 @@ func (api *TransactionAPI) SignTransaction(ctx context.Context, args Transaction
18251825 return nil , err
18261826 }
18271827 // Before actually sign the transaction, ensure the transaction fee is reasonable.
1828- tx := args .ToTransaction (types .LegacyTxType )
1828+ tx := args .ToTransaction (types .DynamicFeeTxType )
18291829 if err := checkTxFee (tx .GasPrice (), tx .Gas (), api .b .RPCTxFeeCap ()); err != nil {
18301830 return nil , err
18311831 }
@@ -1881,7 +1881,7 @@ func (api *TransactionAPI) Resend(ctx context.Context, sendArgs TransactionArgs,
18811881 if err := sendArgs .setDefaults (ctx , api .b , sidecarConfig {}); err != nil {
18821882 return common.Hash {}, err
18831883 }
1884- matchTx := sendArgs .ToTransaction (types .LegacyTxType )
1884+ matchTx := sendArgs .ToTransaction (types .DynamicFeeTxType )
18851885
18861886 // Before replacing the old transaction, ensure the _new_ transaction fee is reasonable.
18871887 price := matchTx .GasPrice ()
@@ -1911,7 +1911,7 @@ func (api *TransactionAPI) Resend(ctx context.Context, sendArgs TransactionArgs,
19111911 if gasLimit != nil && * gasLimit != 0 {
19121912 sendArgs .Gas = gasLimit
19131913 }
1914- signedTx , err := api .sign (sendArgs .from (), sendArgs .ToTransaction (types .LegacyTxType ))
1914+ signedTx , err := api .sign (sendArgs .from (), sendArgs .ToTransaction (types .DynamicFeeTxType ))
19151915 if err != nil {
19161916 return common.Hash {}, err
19171917 }
0 commit comments