Fix unverified contact method is displayed#53864
Conversation
|
@hoangzinh @MonilBhavsar One of you needs to 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] |
Reviewer Checklist
Screenshots/VideosAndroid: Native53864_android_native.movAndroid: mWeb Chrome53864_android_web.moviOS: Native53864_ios_native.moviOS: mWeb Safari53864_ios_web.movMacOS: Chrome / Safari53864_web_chrome.movMacOS: Desktop53864_web_desktop.mov |
| if (!isEmptyObject(loginData?.errorFields) && pendingContactAction?.contactMethod) { | ||
| if (pendingContactAction?.contactMethod) { |
There was a problem hiding this comment.
Is it safe to not check loginData?.errorFields here @mkzie2? I tested it and it does solve our problem, but I was thinking about Shahidullah-Muffakir's proposal, do you think it makes sense? I find it strange that I can reproduce the issue only if I close the error manually, otherwise everything happens normally.
There was a problem hiding this comment.
@brunovjk It's safe because we've updated contactMethod to null in successData when adding a new contact method successfully. In the past, the bug doesn't happen because if (loginData?.errorFields && pendingContactAction?.contactMethod) { this condition is always matched when we close the validate code modal.
There was a problem hiding this comment.
I see, that makes sense, thanks for clarifying. Finishing the checklist.
|
@mkzie2 are you able to address the comments since this PR is fixing a blocker? |
Fix unverified contact method is displayed (cherry picked from commit 03f19c1) (CP triggered by luacmartins)
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Cherry-picked to staging by https://github.com/luacmartins in version: 9.0.73-8 🚀
@Expensify/applauseleads please QA this PR and check it off on the deploy checklist if it passes. |
|
🚀 Deployed to production by https://github.com/luacmartins in version: 9.0.73-8 🚀
|
Explanation of Change
Fix unverified contact method is displayed
Fixed Issues
$ #53819
PROPOSAL:
Tests
Offline tests
None
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Screen.Recording.2024-12-10.at.22.01.45.mov
Android: mWeb Chrome
Screen.Recording.2024-12-10.at.21.59.12.mov
iOS: Native
Screen.Recording.2024-12-10.at.22.03.20.mov
iOS: mWeb Safari
Screen.Recording.2024-12-10.at.21.59.57.mov
MacOS: Chrome / Safari
Screen.Recording.2024-12-10.at.21.56.34.mov
MacOS: Desktop
Screen.Recording.2024-12-10.at.22.05.14.mov