From 6799e786a5f37bf63dbd1cf31710a975e9a11a67 Mon Sep 17 00:00:00 2001 From: Bernhard Owen Josephus Date: Mon, 12 Aug 2024 21:43:09 +0800 Subject: [PATCH] fix wrong report ID when join thread --- src/pages/home/report/ContextMenu/ContextMenuActions.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/pages/home/report/ContextMenu/ContextMenuActions.tsx b/src/pages/home/report/ContextMenu/ContextMenuActions.tsx index aec92fd360e9..50b7e9c76153 100644 --- a/src/pages/home/report/ContextMenu/ContextMenuActions.tsx +++ b/src/pages/home/report/ContextMenu/ContextMenuActions.tsx @@ -341,16 +341,17 @@ const ContextMenuActions: ContextMenuAction[] = [ }, onPress: (closePopover, {reportAction, reportID}) => { const childReportNotificationPreference = ReportUtils.getChildReportNotificationPreference(reportAction); + const originalReportID = ReportUtils.getOriginalReportID(reportID, reportAction); if (closePopover) { hideContextMenu(false, () => { ReportActionComposeFocusManager.focus(); - Report.toggleSubscribeToChildReport(reportAction?.childReportID ?? '-1', reportAction, reportID, childReportNotificationPreference); + Report.toggleSubscribeToChildReport(reportAction?.childReportID ?? '-1', reportAction, originalReportID, childReportNotificationPreference); }); return; } ReportActionComposeFocusManager.focus(); - Report.toggleSubscribeToChildReport(reportAction?.childReportID ?? '-1', reportAction, reportID, childReportNotificationPreference); + Report.toggleSubscribeToChildReport(reportAction?.childReportID ?? '-1', reportAction, originalReportID, childReportNotificationPreference); }, getDescription: () => {}, },