From 2831fef789dfab1114f965037243425650128b0d Mon Sep 17 00:00:00 2001 From: Youssef Lourayad Date: Tue, 6 Feb 2024 19:13:01 +0100 Subject: [PATCH 1/2] Fix condition evaluation to false due to param being a string --- src/components/ReportActionItem/MoneyRequestAction.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ReportActionItem/MoneyRequestAction.tsx b/src/components/ReportActionItem/MoneyRequestAction.tsx index ff29bf5b0ee8..82098b52f2c3 100644 --- a/src/components/ReportActionItem/MoneyRequestAction.tsx +++ b/src/components/ReportActionItem/MoneyRequestAction.tsx @@ -92,7 +92,7 @@ function MoneyRequestAction({ } // If the childReportID is not present, we need to create a new thread - const childReportID = action?.childReportID ?? '0'; + const childReportID = action?.childReportID ?? 0; if (!childReportID) { const thread = ReportUtils.buildTransactionThread(action, requestReportID); const userLogins = PersonalDetailsUtils.getLoginsByAccountIDs(thread.participantAccountIDs ?? []); From 6c2abde357968c1d38730cd379b3fd654130e766 Mon Sep 17 00:00:00 2001 From: Youssef Lourayad Date: Tue, 6 Feb 2024 19:35:22 +0100 Subject: [PATCH 2/2] Update src/components/ReportActionItem/MoneyRequestAction.tsx Co-authored-by: Aldo Canepa Garay <87341702+aldo-expensify@users.noreply.github.com> --- src/components/ReportActionItem/MoneyRequestAction.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ReportActionItem/MoneyRequestAction.tsx b/src/components/ReportActionItem/MoneyRequestAction.tsx index 82098b52f2c3..9e169b23391a 100644 --- a/src/components/ReportActionItem/MoneyRequestAction.tsx +++ b/src/components/ReportActionItem/MoneyRequestAction.tsx @@ -92,7 +92,7 @@ function MoneyRequestAction({ } // If the childReportID is not present, we need to create a new thread - const childReportID = action?.childReportID ?? 0; + const childReportID = action?.childReportID; if (!childReportID) { const thread = ReportUtils.buildTransactionThread(action, requestReportID); const userLogins = PersonalDetailsUtils.getLoginsByAccountIDs(thread.participantAccountIDs ?? []);