Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions packages/transaction-controller/src/TransactionController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -592,8 +592,8 @@ export class TransactionController extends BaseController<
unsignedEthTx,
transactionMeta.transaction.from,
);
const rawTransaction = bufferToHex(signedTx.serialize());
await query(this.ethQuery, 'sendRawTransaction', [rawTransaction]);
const rawTx = bufferToHex(signedTx.serialize());
await query(this.ethQuery, 'sendRawTransaction', [rawTx]);
transactionMeta.estimatedBaseFee = estimatedBaseFee;
transactionMeta.status = TransactionStatus.cancelled;
this.hub.emit(`${transactionMeta.id}:finished`, transactionMeta);
Expand Down Expand Up @@ -703,9 +703,9 @@ export class TransactionController extends BaseController<
unsignedEthTx,
transactionMeta.transaction.from,
);
const rawTransaction = bufferToHex(signedTx.serialize());
const rawTx = bufferToHex(signedTx.serialize());
const transactionHash = await query(this.ethQuery, 'sendRawTransaction', [
rawTransaction,
rawTx,
]);
const baseTransactionMeta = {
...transactionMeta,
Expand Down Expand Up @@ -1112,12 +1112,12 @@ export class TransactionController extends BaseController<
const signedTx = await this.sign(unsignedEthTx, from);
transactionMeta.status = TransactionStatus.signed;
this.updateTransaction(transactionMeta);
const rawTransaction = bufferToHex(signedTx.serialize());
const rawTx = bufferToHex(signedTx.serialize());

transactionMeta.rawTransaction = rawTransaction;
transactionMeta.rawTx = rawTx;
this.updateTransaction(transactionMeta);
const transactionHash = await query(this.ethQuery, 'sendRawTransaction', [
rawTransaction,
rawTx,
]);
transactionMeta.transactionHash = transactionHash;
transactionMeta.status = TransactionStatus.submitted;
Expand Down
2 changes: 1 addition & 1 deletion packages/transaction-controller/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ type TransactionMetaBase = {
/**
* Hex representation of the underlying transaction.
*/
rawTransaction?: string;
rawTx?: string;

/**
* When the transaction is dropped, this is the replacement transaction hash.
Expand Down