From c19e3b73060464a94401fe89b191df075ab7893d Mon Sep 17 00:00:00 2001 From: Aaron Cook Date: Thu, 7 Dec 2023 06:53:17 +0100 Subject: [PATCH] refactor: improve `isRecoveryQueueItem` strictness (#2952) --- src/utils/transaction-guards.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/utils/transaction-guards.ts b/src/utils/transaction-guards.ts index 9245d3a842..a5c509e42f 100644 --- a/src/utils/transaction-guards.ts +++ b/src/utils/transaction-guards.ts @@ -117,7 +117,8 @@ export const isTransactionListItem = (value: TransactionListItem): value is Tran } export function isRecoveryQueueItem(value: TransactionListItem | RecoveryQueueItem): value is RecoveryQueueItem { - return 'args' in value + const EVENT_SIGNATURE = 'TransactionAdded(uint256,bytes32,address,uint256,bytes,uint8)' + return 'eventSignature' in value && value.eventSignature === EVENT_SIGNATURE } // Narrows `Transaction`