Repository navigation
fix: keep the quote when replying in direct message to a thread message #7899
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
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
f1bee44
fix: keep the quote when replying in direct message to a thread message
OtavioStasiak 9c4a033
refactor: keep getMessageById a messages-only lookup and move touched…
OtavioStasiak 9af7d29
refactor: drop tmid from quote message lookup
OtavioStasiak cc9e342
refactor: drop the empty-id guard from getMessageOrThreadMessageById
OtavioStasiak 5639794
Merge branch 'develop' into fix.reply-from-thread-and-quote
OtavioStasiak File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
app/containers/MessageComposer/helpers/prepareQuoteMessage.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Script executed:
Repository: RocketChat/Rocket.Chat.ReactNative
Length of output: 8123
Script executed:
Repository: RocketChat/Rocket.Chat.ReactNative
Length of output: 4924
Script executed:
Repository: RocketChat/Rocket.Chat.ReactNative
Length of output: 5589
Script executed:
Repository: RocketChat/Rocket.Chat.ReactNative
Length of output: 4670
Keep the thread-parent fallback in the quote lookup.
A thread parent that exists only in the
threadstable can still be shown in the thread view. The old quote lookup in a thread context returned that parent throughgetThreadById.getMessageOrThreadMessageByIdnow checks onlymessagesandthread_messages, so the same parent returnsnull. The quote preview and the quote in the sent message are then dropped.Add the
threadslookup back togetMessageOrThreadMessageById, after themessagesandthread_messageslookups. The preview and send paths both use this function, so both return the parent. Keep thethread_messageslookup that fixes the DM thread-reply case.