Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/libs/actions/Report.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import * as PersonalDetailsUtils from '@libs/PersonalDetailsUtils';
import * as Pusher from '@libs/Pusher/pusher';
import * as ReportActionsUtils from '@libs/ReportActionsUtils';
import * as ReportUtils from '@libs/ReportUtils';
import shouldSkipDeepLinkNavigation from '@libs/shouldSkipDeepLinkNavigation';
import * as UserUtils from '@libs/UserUtils';
import Visibility from '@libs/Visibility';
import CONFIG from '@src/CONFIG';
Expand Down Expand Up @@ -2032,6 +2033,10 @@ function openReportFromDeepLink(url: string, isAuthenticated: boolean) {
return;
}

if (shouldSkipDeepLinkNavigation(route)) {
return;
}

Navigation.navigate(route as Route, CONST.NAVIGATION.ACTION_TYPE.PUSH);
});
});
Expand Down
12 changes: 12 additions & 0 deletions src/libs/shouldSkipDeepLinkNavigation/index.desktop.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import ROUTES from '@src/ROUTES';

export default function shouldSkipDeepLinkNavigation(route: string) {
// When deep-linking to desktop app with `transition` route we don't want to call navigate
// on the route because it will display an infinite loading indicator.
// See issue: https://github.com/Expensify/App/issues/33149
if (route.includes(ROUTES.TRANSITION_BETWEEN_APPS)) {
return true;
}

return false;
}
5 changes: 5 additions & 0 deletions src/libs/shouldSkipDeepLinkNavigation/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
// eslint-disable-next-line @typescript-eslint/no-unused-vars
export default function shouldSkipDeepLinkNavigation(route: string) {
// no-op for all other platforms
return false;
}