diff --git a/ironfish/src/rpc/routes/chain/getTransaction.test.ts b/ironfish/src/rpc/routes/chain/getTransaction.test.ts index 0f1cf15e95..f3197c4748 100644 --- a/ironfish/src/rpc/routes/chain/getTransaction.test.ts +++ b/ironfish/src/rpc/routes/chain/getTransaction.test.ts @@ -18,11 +18,9 @@ describe('Route chain/getTransaction', () => { const transaction = block2.transactions[0] - const notesEncrypted: string[] = [] const notes: { hash: string; serialized: string }[] = [] for (const note of transaction.notes) { - notesEncrypted.push(note.serialize().toString('hex')) notes.push({ hash: note.hash().toString('hex'), serialized: note.serialize().toString('hex'), @@ -44,10 +42,7 @@ describe('Route chain/getTransaction', () => { expect(response.content).toMatchObject({ fee: Number(transaction.fee()), expiration: transaction.expiration(), - notesCount: 1, - spendsCount: 0, signature: transaction.transactionSignature().toString('hex'), - notesEncrypted, spends, mints: [], burns: [], @@ -63,11 +58,9 @@ describe('Route chain/getTransaction', () => { const transaction = block2.transactions[0] - const notesEncrypted: string[] = [] const notes: { hash: string; serialized: string }[] = [] for (const note of transaction.notes) { - notesEncrypted.push(note.serialize().toString('hex')) notes.push({ hash: note.hash().toString('hex'), serialized: note.serialize().toString('hex'), @@ -90,10 +83,7 @@ describe('Route chain/getTransaction', () => { expect(response.content).toMatchObject({ fee: Number(transaction.fee()), expiration: transaction.expiration(), - notesCount: 1, - spendsCount: 0, signature: transaction.transactionSignature().toString('hex'), - notesEncrypted, spends, mints: [], burns: [], diff --git a/ironfish/src/rpc/routes/chain/getTransaction.ts b/ironfish/src/rpc/routes/chain/getTransaction.ts index f288f2bfdf..dfcb2f85a5 100644 --- a/ironfish/src/rpc/routes/chain/getTransaction.ts +++ b/ironfish/src/rpc/routes/chain/getTransaction.ts @@ -16,18 +16,6 @@ export type GetTransactionRequest = { transactionHash: string; blockHash?: strin export type GetTransactionResponse = RpcTransaction & { noteSize: number blockHash: string - /** - * @deprecated Please use `notes.length` instead - */ - notesCount: number - /** - * @deprecated Please use `spends.length` instead - */ - spendsCount: number - /** - * @deprecated Please use `notes` instead - */ - notesEncrypted: string[] } export const GetTransactionRequestSchema: yup.ObjectSchema = yup @@ -41,9 +29,6 @@ export const GetTransactionResponseSchema: yup.ObjectSchema( ...serializeRpcTransaction(chainTransaction.transaction, true), blockHash: blockHashBuffer.toString('hex'), noteSize: chainTransaction.initialNoteIndex + chainTransaction.transaction.notes.length, - notesCount: chainTransaction.transaction.notes.length, - spendsCount: chainTransaction.transaction.spends.length, - notesEncrypted: chainTransaction.transaction.notes.map((note) => - note.serialize().toString('hex'), - ), }) }, )