Skip to content
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: showing wrong chat ("Reply Privately" quote) #4511

Merged
merged 2 commits into from
Jan 20, 2025

Conversation

WofWca
Copy link
Collaborator

@WofWca WofWca commented Jan 19, 2025

  1. "Reply Privately" to a message in a group.
  2. Click on the quote. This will open the original chat.
  3. Click the "jump down" button.

This will load the messages from the private chat,
but still show the original group chat in the chat header.

@WofWca WofWca force-pushed the wofwca/jumpToMessage-improvements branch from 5159c50 to feae518 Compare January 19, 2025 10:40
@WofWca WofWca force-pushed the wofwca/jumpToMessage-improvements branch from feae518 to 6282970 Compare January 19, 2025 10:43
@WofWca WofWca force-pushed the wofwca/jumpToMessage-improvements branch from 6282970 to c505c51 Compare January 19, 2025 10:48
@WofWca WofWca force-pushed the wofwca/jumpToMessage-improvements branch from c505c51 to 903ca2b Compare January 19, 2025 11:23
@WofWca WofWca changed the title jumpToMessage fixes and improvements fix: showing wrong chat ("Reply Privately" quote) Jan 19, 2025
@WofWca WofWca marked this pull request as ready for review January 19, 2025 11:25
@WofWca WofWca force-pushed the wofwca/jumpToMessage-improvements branch from 903ca2b to d1f8f1c Compare January 19, 2025 11:31
Copy link
Member

@nicodh nicodh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When testing I see constantly the (new) error log:

Tried to show messages from a different chat.
this.accountId === 1, this.chatId === 13, target IDs: 1, 14. jumpToMessageId === 81

I see that the correct group chat ID is fetched from backend (14) for the correct msgId from the quote (81), but when jump_to_message is performed still the chatId of the private chat is in this.chatId

Edit: this happens even before clicking the "jump down" button

Also add a runtime warning.

The `MessageListStore` re-creation logic
was apparently introduced in cf9eb1f.
1. "Reply Privately" to a message in a group.
2. Click on the quote. This will open the original chat.
3. Click the "jump down" button.

This will load the messages from the private chat,
but still show the original group chat in the chat header.
@WofWca WofWca force-pushed the wofwca/jumpToMessage-improvements branch from d1f8f1c to 36584ff Compare January 20, 2025 16:00
@WofWca
Copy link
Collaborator Author

WofWca commented Jan 20, 2025

Right, I rebased on top of #4510, and the error is no longer printed for me.
Because that MR fixed that error. Perhaps I should have added this check to that MR.

@WofWca WofWca requested a review from nicodh January 20, 2025 16:00
Copy link
Member

@nicodh nicodh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review by Testing & Reading

@WofWca WofWca merged commit 42a580a into main Jan 20, 2025
14 checks passed
@WofWca WofWca deleted the wofwca/jumpToMessage-improvements branch January 20, 2025 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants