Skip to content

Commit cbd447a

Browse files
author
Test User
committed
rename TransactionReceipt.id to hash
1 parent ec61563 commit cbd447a

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

src/wallet-account-read-only-evm-erc-4337.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,7 @@ export default class WalletAccountReadOnlyEvmErc4337 extends WalletAccountReadOn
406406

407407
if (!userOpByHash.transactionHash) {
408408
return {
409-
id: hash,
409+
hash,
410410
finality: 'pending',
411411
confirmations: 0,
412412
transaction: null,
@@ -427,7 +427,7 @@ export default class WalletAccountReadOnlyEvmErc4337 extends WalletAccountReadOn
427427

428428
return {
429429
...info,
430-
id: hash,
430+
hash,
431431
success: userOpReceipt ? userOpReceipt.success : info.success,
432432
fee: userOpReceipt ? userOpReceipt.actualGasCost : info.fee,
433433
userOperationReceipt: userOpReceipt

tests/wallet-account-read-only-evm-erc-4337.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ const DUMMY_TX_RECEIPT = {
106106
}
107107

108108
const DUMMY_EVM_TX_INFO = {
109-
id: DUMMY_TX_HASH,
109+
hash: DUMMY_TX_HASH,
110110
finality: 'confirmed',
111111
success: true,
112112
block: '0x' + '22'.repeat(32),
@@ -496,7 +496,7 @@ describe('@tetherto/wdk-wallet-evm-erc-4337', () => {
496496

497497
const info = await account.getTransaction(DUMMY_USER_OP_HASH)
498498

499-
expect(info.id).toBe(DUMMY_USER_OP_HASH)
499+
expect(info.hash).toBe(DUMMY_USER_OP_HASH)
500500
expect(info.finality).toBe('confirmed')
501501
expect(info.confirmations).toBe(3)
502502
expect(info.success).toBe(true)

0 commit comments

Comments
 (0)