-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Fix conditional statement for hasOutstandingChildRequest
when calculating the optimistic data for IOU requests
#38431
Conversation
hasOutstandingChildRequest
hasOutstandingChildRequest
hasOutstandingChildRequest
when calculating the optimistic data for IOU requests
@paultsimura, it seems like ESLint doesn't think that |
@getusha I'm assigning @paultsimura as a C+ as they proposed a solution. |
Thanks, I'll review within 2 hours |
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.
Also, let's try to move the needsToBeManuallySubmitted
function from IOU
to ReportUtils
– it's not an Action (doesn't modify any data with API calls), so its place in Utils, not Actions.
Reviewer Checklist
Screenshots/VideosAndroid: NativeAndroid16.27.mp4Android: mWeb Chromechrome16.30.mp4iOS: NativeSimulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-03-16.at.16.25.5416.26.mp4iOS: mWeb SafariSimulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-03-16.at.16.33.1916.33.mp4MacOS: Chrome / SafariScreen.Recording.2024-03-16.at.16.15.3616.16.mp4MacOS: DesktopScreen.Recording.2024-03-16.at.16.17.4516.18.mp4 |
Thanks, I'll retest today — have one potential concern about this logic🤔 |
@hayata-suenaga Unfortunately, this issue is more complex than I thought initially. I think, it will be more efficient to assign me here as a Contributor (because the fix requires quite a lot of digging into the logic and plenty of changes), and have @situchan as a C+ as from my experience, he's very thorough in testing different edge cases, and this PR should be about quite a few different flows. WDYT? |
@paultsimura that sounds good to me. could you provide an updated proposal in the original issue? also, should we close this PR? |
Yes, I think we can close this one. I will update my proposal shortly 👍 |
Details
This PR fixes the conditional statement to check if the report has an outstanding money request. These conditional statements are inside the IOU action function that is responsible for updating the merchant field of a report.
These conditional statements are used when creating the optimistic update for the report.
Fixed Issues
$ #38425
PROPOSAL: #38425 (comment)
Tests / QA Steps
Offline tests
N/A
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.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 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
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
test.mov
MacOS: Desktop