-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Fix: Migrated User Modal shows twice #58348
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@ishpaul777 Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
I am updating the video in Android platform Edit: I updated video in Android platform |
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2025-03-16.at.12.28.11.AM.movAndroid: mWeb ChromeScreen.Recording.2025-03-16.at.12.23.03.AM.moviOS: NativeScreen.Recording.2025-03-16.at.12.13.13.AM.moviOS: mWeb SafariScreen.Recording.2025-03-16.at.12.18.43.AM.movMacOS: Chrome / SafariScreen.Recording.2025-03-15.at.11.56.28.PM.movMacOS: DesktopScreen.Recording.2025-03-15.at.11.53.05.PM.mov |
path?.includes(ROUTES.MIGRATED_USER_WELCOME_MODAL) && | ||
lastVisitedPath && | ||
!CONFIG.IS_HYBRID_APP && | ||
isOnboardingCompleted && | ||
!wasInvitedToNewDot && | ||
authenticated && | ||
!shouldShowRequire2FAModal |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need these many conditions ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I’ve updated the PR to remove the redundant condition. The new condition is:
path?.includes(ROUTES.MIGRATED_USER_WELCOME_MODAL) && lastVisitedPath && !CONFIG.IS_HYBRID_APP && isOnboardingCompleted && authenticated
This ensures the logic only runs if the user is not in a hybrid app (since I can’t test that), the onboarding flow is completed, and the user is authenticated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the onboarding flow is completed, and the user is authenticated.
how Is this relevant, will such user ever lands on this route?
also I think !CONFIG.IS_HYBRID_APP is not relevant
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how Is this relevant, will such user ever lands on this route?
When testing the PR without the isOnboardingCompleted
condition, the logic in:
App/src/libs/Navigation/NavigationRoot.tsx
Line 122 in fee6c80
return getAdaptedStateFromPath(getOnboardingInitialPath(isPrivateDomain), linkingConfig.config); |
doesn’t run because the new logic causes an early return with:
return getAdaptedStateFromPath(lastVisitedPath, linkingConfig.config)
we have conflicts @truph01 |
@ishpaul777 I just fixed the conflict and removed |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/neil-marcellini in version: 9.1.17-0 🚀
|
🚀 Deployed to production by https://github.com/cristipaval in version: 9.1.17-1 🚀
|
Explanation of Change
Fixed Issues
$ #58047
PROPOSAL: #58047 (comment)
Tests
src/hooks/useOnboardingFlow.ts
:Or (For QA):
open app and Go to settings Troublshoot > enable Client side logging, then click on "View debug console" execute below command:
Offline tests
QA Steps
src/hooks/useOnboardingFlow.ts
:Or (For QA):
open app and Go to settings Troublshoot > enable Client side logging, then click on "View debug console" execute below command:
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Screen.Recording.2025-03-13.at.15.45.47.mov
Android: mWeb Chrome
Screen.Recording.2025-03-13.at.15.17.38.mov
iOS: Native
output.mp4
iOS: mWeb Safari
Screen.Recording.2025-03-13.at.15.15.07.mov
MacOS: Chrome / Safari
Screen.Recording.2025-03-13.at.15.07.23.mov
MacOS: Desktop
Screen.Recording.2025-03-13.at.15.21.46.mov