Page MenuHomePhabricator

[keyserver] Update fetchPinnedMessageInfos to retrieve related messages
ClosedPublic

Authored by rohan on May 6 2023, 1:18 PM.
Tags
None
Referenced Files
F3620632: D7736.id26144.diff
Thu, Jan 2, 12:37 AM
F3620631: D7736.id26142.diff
Thu, Jan 2, 12:37 AM
F3620584: D7736.id.diff
Thu, Jan 2, 12:36 AM
F3620454: D7736.diff
Thu, Jan 2, 12:22 AM
Unknown Object (File)
Oct 30 2024, 3:15 PM
Unknown Object (File)
Oct 29 2024, 5:35 AM
Unknown Object (File)
Oct 28 2024, 6:39 AM
Unknown Object (File)
Sep 28 2024, 8:02 AM
Subscribers

Details

Summary

Update fetchPinnedMessageInfos to now retrieve the related messages (reactions, edits, etc.) using the new function. The ongoing native stack can rebase these changes once landed so no additional work will be needed there.

One point of discussion is whether the use of messageListData is still needed. I'm under the impression, after some investigation, that it is necessary still since we need to construct ChatMessageInfoItems from all of the message infos. The only change this diff should help with is preventing missing related messages for ones not accessible from messageStore.

I'll continue confirming if this is the case locally, however, in the meantime and am open to discussion

Test Plan

Confirm that related messages are fetched directly now.

Through the console:

[
  {
    type: 0,
    id: '85555',
    threadID: '85545',
    time: 1679763761385,
    creatorID: '256',
    text: 'Sample new thread'
  },
  {
    type: 19,
    id: '90779',
    threadID: '85545',
    time: 1683401422863,
    creatorID: '256',
    targetMessageID: '85555',
    reaction: '👍',
    action: 'add_reaction'
  }
]

Also confirmed via the thread pinned messages modal on web, with a before and after to show the reaction for a message from several months ago now appears after these changes.

Before:

Screenshot 2023-05-06 at 4.07.09 PM.png (1×1 px, 286 KB)

After:

Screenshot 2023-05-06 at 4.07.37 PM.png (1×1 px, 286 KB)

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

rohan edited the test plan for this revision. (Show Details)
rohan added a reviewer: atul.
rohan edited the test plan for this revision. (Show Details)
rohan requested review of this revision.May 6 2023, 1:38 PM
This revision is now accepted and ready to land.May 7 2023, 8:14 AM