diff --git a/src/libs/actions/Report.ts b/src/libs/actions/Report.ts index ed984080ff6c..bc5f7a347cd0 100644 --- a/src/libs/actions/Report.ts +++ b/src/libs/actions/Report.ts @@ -2668,9 +2668,15 @@ function openReportFromDeepLink(url: string) { // Navigate to the report after sign-in/sign-up. InteractionManager.runAfterInteractions(() => { Session.waitForUserSignIn().then(() => { - Onyx.connect({ + const connection = Onyx.connect({ key: ONYXKEYS.NVP_ONBOARDING, callback: (onboarding) => { + if (onboarding) { + // Once the onboarding data is available, we want to disconnect the connection + // so it won't trigger the deeplink again every time the data is changed, for example, when relogin. + Onyx.disconnect(connection); + } + Navigation.waitForProtectedRoutes().then(() => { if (route && Session.isAnonymousUser() && !Session.canAnonymousUserAccessRoute(route)) { Session.signOutAndRedirectToSignIn(true);