HomePhabricator
Diffusion Comm 8a3e94c97c73

[lib] introduced rawMessageInfoFromServerDBRow function to reaction message spec

Description

[lib] introduced rawMessageInfoFromServerDBRow function to reaction message spec

Summary:
introduced rawMessageInfoFromServerDBRow function to reaction message spec. rawMessageInfoFromServerDBRow does some basic parsing of the message content from the db and returns the information necessary for a RawReactionMessageInfo object

UPDATE

Got some feedback to grab targetMessageID directly from the messages table instead of from messageContent. To do this successfully, I had to modify some of the message-fetchers queries to include targetMessageID in the query selection.


Depends on D5690
Linear Task: ENG-2245

Test Plan:
Ran web and mobile app locally and nothing crashes/there are no regressions. More testing of this function will come in subsequent diffs.

UPDATE

To test that the queries were returning the correct information, I logged out row.targetMessageID.toString() and got this result, which matched what I found in the database:

Screenshot 2022-12-07 at 5.16.14 PM.png (166×424 px, 78 KB)

Screenshot 2022-12-07 at 5.34.55 PM.png (1×3 px, 1 MB)

(also note that the message content no longer has targetMessageID)

Reviewers: atul, tomek, rohan

Reviewed By: atul, tomek

Subscribers: ashoat, tomek, atul

Differential Revision: https://phab.comm.dev/D5803

Details

Provenance
ginsuAuthored on Dec 15 2022, 12:18 PM
Reviewer
atul
Differential Revision
D5803: [lib] introduced rawMessageInfoFromServerDBRow function to reaction message spec
Parents
rCOMM14853b1cafe1: [native] Block link press if spoiler is not yet revealed
Branches
Unknown
Tags
Unknown