Skip to content

Commit fe8dcfe

Browse files
committed
Small refactor to TP sim
1 parent 02cf672 commit fe8dcfe

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

packages/transaction-preview/src/simulateTransactions.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const simulateTransactions = async (
1818
const cleanedTrans = {
1919
from: convertedTransaction.from,
2020
to: convertedTransaction.to,
21-
gas: convertedTransaction.gas,
21+
gas: convertedTransaction.gas || convertedTransaction.gasLimit || 0,
2222
gasPrice: convertedTransaction.gasPrice,
2323
maxFeePerGas: convertedTransaction.maxFeePerGas,
2424
maxPriorityFeePerGas: convertedTransaction.maxPriorityFeePerGas,

packages/transaction-preview/src/utils.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ type TransactionRequestWithNumberFields = TransactionForSim & {
4242
gas: number
4343
value: number
4444
gasPrice?: number
45+
gasLimit?: number
4546
maxPriorityFeePerGas?: number
4647
maxFeePerGas?: number
4748
}

0 commit comments

Comments
 (0)