File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
packages/transaction-controller/src Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -4127,14 +4127,14 @@ export class TransactionController extends BaseController<
41274127 } ,
41284128 ) ;
41294129
4130- log ( 'Calling afterSimulate hook' , finalTransactionMeta ) ;
4131-
41324130 if ( ethQuery ) {
4131+ log ( 'Calling afterSimulate hook' , finalTransactionMeta ) ;
4132+
41334133 const result = await this . #afterSimulate( {
41344134 transactionMeta : finalTransactionMeta ,
41354135 } ) ;
41364136
4137- if ( result . updateTransaction ) {
4137+ if ( result ? .updateTransaction ) {
41384138 log ( 'Updating transaction with afterSimulate data' ) ;
41394139
41404140 finalTransactionMeta = this . #updateTransactionInternal(
@@ -4150,6 +4150,8 @@ export class TransactionController extends BaseController<
41504150 txParams : { ...finalTransactionMeta . txParams , gas : undefined } ,
41514151 } ) ;
41524152
4153+ log ( 'Updating gas following afterSimulate hook' , estimatedGas ) ;
4154+
41534155 finalTransactionMeta = this . #updateTransactionInternal(
41544156 { transactionId } ,
41554157 ( txMeta ) => {
You can’t perform that action at this time.
0 commit comments