Page MenuHomePhabricator

[lib] Fix crash when pressing message from anonymous author
ClosedPublic

Authored by ashoat on Jul 6 2024, 2:42 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Jul 23, 11:25 PM
Unknown Object (File)
Mon, Jul 22, 10:21 PM
Unknown Object (File)
Mon, Jul 22, 7:20 AM
Unknown Object (File)
Fri, Jul 19, 4:00 AM
Unknown Object (File)
Wed, Jul 17, 11:25 PM
Unknown Object (File)
Sun, Jul 14, 1:15 AM
Unknown Object (File)
Sat, Jul 13, 3:02 AM
Unknown Object (File)
Fri, Jul 12, 6:37 PM
Subscribers
None

Details

Summary

If we don't have a username for a message author, the app currently crashing when you press the message.

It looks like the Flow types here are unnecessarily strict. Once I relaxed them, I was able to remove the invariant.

This resolves ENG-8777.

Depends on D12679

Test Plan

I reverted D12674 to reproduce the issue. I then created a new user from a separate account, and sent a message to my main user. The main user was able to press the message, react, and start a sidebar on the messages for the other user, even though the other user showed up as "anonymous"

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable