Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Nodebrute committed May 15, 2024
1 parent beee045 commit c1eb93d
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/pages/home/ReportScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -525,6 +525,10 @@ function ReportScreen({
isRemovalExpectedForReportType ||
isClosedTopLevelPolicyRoom
) {
// If the report isn't focused, navigation to Concierge Chat should be avoided.
if (!isFocused) {
return;
}
Navigation.dismissModal();
if (Navigation.getTopmostReportId() === prevOnyxReportID) {
Navigation.setShouldPopAllStateOnUP();
Expand All @@ -539,10 +543,7 @@ function ReportScreen({
Navigation.navigate(ROUTES.REPORT_WITH_ID.getRoute(prevReport.parentReportID));
return;
}
// If the report isn't focused, navigation to Concierge Chat should be avoided.
if (!isFocused) {
return;
}

Report.navigateToConciergeChat();
return;
}
Expand Down

0 comments on commit c1eb93d

Please sign in to comment.