-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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: Missing 'Leave Thread' Button Offline in Self DM Thread #39993
Conversation
@shubham1206agra 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] |
Reviewer Checklist
Screenshots/VideosAndroid: NativeAndroid: mWeb Chrome |
Sorry, I know I approved the proposal, but I don't totally understand why this works. It looks like here, this logic is based on the report, not the parentReport. So why does setting the type of the parentReport to undefined make this work? |
@puneetlath The parentReport here is the report from which you pressed the reply in thread button. And the report you are referencing is the child report created by this action.
We are not setting the type of |
Ok, hm, I see. It feels a bit weird to do this:
Like it works, but it just feels unintuitive. If I read that code, I'd have no idea why we're doing that. Could we have the isSelfDM function handle this logic instead? |
@nkdengineer Can you please update to reflect the same? |
@shubham1206agra @puneetlath I updated PR based on suggestion |
@puneetlath You can merge this now. |
Sorry, that's not quite what I meant. I was saying that instead of setting the optimistic value of the parentReport.chatType to |
That will be wrong as every thread created from |
@puneetlath Can you check this comment? |
@puneetlath Bump on this comment. |
@shubham1206agra @puneetlath i added comment |
@puneetlath Can you approve this PR now? |
Thanks for working through that! I think the code is much clearer this way 😄 |
✋ 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/puneetlath in version: 1.4.67-0 🚀
|
Hey @puneetlath @shubham1206agra. This is a bit of a long-shot, but do you think modifying the chatType param could have introduced this new issue: 'App redirects to Concierge chat when leaving group chat and room'? |
@Julesssss Nope, confirmed that I can still repro on reverting locally. |
Thanks, yeah I just confirmed that the issue doesn't occur on the commit that merged this to main 👍 |
🚀 Deployed to production by https://github.com/francoisl in version: 1.4.67-7 🚀
|
1 similar comment
🚀 Deployed to production by https://github.com/francoisl in version: 1.4.67-7 🚀
|
Details
Fixed Issues
$ #39618
PROPOSAL: #39618 (comment)
Tests
Offline tests
QA Steps
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.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
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop