Skip to content

Commit

Permalink
Merge pull request #47541 from nkdengineer/fix/47259
Browse files Browse the repository at this point in the history
fix: Back button on expense report reopens same report
  • Loading branch information
NikkiWines authored Aug 19, 2024
2 parents c0a9cbf + 06a9081 commit 212750d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/libs/Navigation/linkTo/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,10 @@ export default function linkTo(navigation: NavigationContainerRef<RootStackParam
// If the type is UP, we deeplinked into one of the RHP flows and we want to replace the current screen with the previous one in the flow
// and at the same time we want the back button to go to the page we were before the deeplink
} else if (type === CONST.NAVIGATION.TYPE.UP) {
if (!areParamsDifferent && isSideModalNavigator(lastRoute?.name) && topmostCentralPaneRoute?.name === targetName) {
dismissModal(navigation);
return;
}
action.type = CONST.NAVIGATION.ACTION_TYPE.REPLACE;

// If this action is navigating to ModalNavigator or FullScreenNavigator and the last route on the root navigator is not already opened Navigator then push
Expand Down

0 comments on commit 212750d

Please sign in to comment.