We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ba687b4 commit 2a2530cCopy full SHA for 2a2530c
1 file changed
src/components/ScreenWrapper/index.tsx
@@ -173,8 +173,9 @@ function ScreenWrapper(
173
const [isSingleNewDotEntry] = useOnyx(ONYXKEYS.IS_SINGLE_NEW_DOT_ENTRY, {canBeMissing: true});
174
const {setRootStatusBarEnabled} = useContext(CustomStatusBarAndBackgroundContext);
175
176
- usePreventRemove((isSingleNewDotEntry ?? false) && initialURL === Navigation.getActiveRouteWithoutParams(), () => {
177
- if (!CONFIG.IS_HYBRID_APP) {
+ usePreventRemove(true, () => {
+ const shouldGoToOD = (isSingleNewDotEntry ?? false) && initialURL === Navigation.getActiveRouteWithoutParams();
178
+ if (!CONFIG.IS_HYBRID_APP || !shouldGoToOD) {
179
return;
180
}
181
HybridAppModule.closeReactNativeApp({shouldSignOut: false, shouldSetNVP: false});
0 commit comments