From b8eb012913bbf14c5fe37df4423e8544d4fe2499 Mon Sep 17 00:00:00 2001 From: Carlos Martins Date: Thu, 12 Dec 2024 08:48:11 -0700 Subject: [PATCH] Revert "Fix pay button after deleting expense" --- src/libs/SearchUIUtils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/SearchUIUtils.ts b/src/libs/SearchUIUtils.ts index ab99cdac0fca..761b8fefb047 100644 --- a/src/libs/SearchUIUtils.ts +++ b/src/libs/SearchUIUtils.ts @@ -271,8 +271,8 @@ function getAction(data: OnyxTypes.SearchResults['data'], key: string): SearchTr return CONST.SEARCH.ACTION_TYPES.DONE; } - // We don't need to run the logic if this is not an iou/expense report, so let's shortcircuit the logic for performance reasons - if (!ReportUtils.isMoneyRequestReport(report)) { + // We don't need to run the logic if this is not a transaction or iou/expense report, so let's shortcircuit the logic for performance reasons + if (!ReportUtils.isMoneyRequestReport(report) || (isTransaction && !data[key].isFromOneTransactionReport)) { return CONST.SEARCH.ACTION_TYPES.VIEW; }