Page MenuHomePhabricator

[lib][native][web] Include viewerID in userInfoSelectorForPotentialMembers
ClosedPublic

Authored by ashoat on Sep 30 2024, 9:53 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Dec 18, 11:53 AM
Unknown Object (File)
Wed, Dec 18, 11:53 AM
Unknown Object (File)
Wed, Dec 18, 11:52 AM
Unknown Object (File)
Wed, Dec 18, 11:52 AM
Unknown Object (File)
Sun, Nov 24, 11:10 PM
Unknown Object (File)
Fri, Nov 22, 12:23 AM
Unknown Object (File)
Nov 21 2024, 4:49 PM
Unknown Object (File)
Nov 10 2024, 4:20 PM
Subscribers
None

Details

Summary

This is the start of a series of diffs that will enable support for creating a PRIVATE thread via the "chat composer", which is the main chat creation interface.

This diff modifies userInfoSelectorForPotentialMembers to include the viewer in its result.

There are 6 callsites of this function. For 4 of the 6 callsites, we reverse this by including the viewerID in excludeUserIDs.

The remaining 2 callsites are MessageListContainer on native, and its equivalent ChatMessageListContainer on web. This intention of this diff is to make the viewerID's UserInfo accessible to the code there, but we'll still need to exclude it in certain cases. The full solution for these is handled in subsequent diff.

Depends on D13539

Test Plan
  1. For the 4/6 callsites where we reversed the inclusion of viewerID via excludeUserIDs, I verified that the result of userInfoSelectorForPotentialMembers wasn't used anywhere else where it would fail to be excluded.
  2. For the 2/6 callsites where we didn't reverse the inclusion, I tested in combination with the following diffs by trying to create a chat with myself via the chat composer.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable