Page MenuHomePhabricator

[lib] Update useUserProfileThreadInfo to consider thick threads
ClosedPublic

Authored by ashoat on Sep 30 2024, 9:42 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 19, 8:54 AM
Unknown Object (File)
Tue, Nov 19, 7:57 AM
Unknown Object (File)
Sun, Nov 10, 4:20 PM
Unknown Object (File)
Fri, Nov 8, 3:00 AM
Unknown Object (File)
Fri, Nov 8, 3:00 AM
Unknown Object (File)
Fri, Nov 1, 4:46 PM
Unknown Object (File)
Fri, Nov 1, 5:37 AM
Unknown Object (File)
Thu, Oct 31, 8:46 PM
Subscribers
None

Details

Summary

If a thick thread exists with the user whose profile we are viewing, we should display it.

When there are multiple, we'll select the oldest thread (by creation time). This matches behavior of pendingToRealizedThreadIDsSelector and useExistingThreadInfoFinder.

Depends on D13532

Test Plan

Tested viewing user profile on both web and native with a user with whom the viewer has a thick thread

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Why do we expect to have multiple private chats, or multiple personal chats with one user? It's it impossible?

In D13533#380315, @inka wrote:

Why do we expect to have multiple private chats, or multiple personal chats with one user? It's it impossible?

It is possible to create multiple PERSONAL threads simultaneously: when a thread is created on a device that is offline, then we create a thread on another device, and then they start sending operations - there will be two PERSONAL threads on both devices.

This revision is now accepted and ready to land.Oct 1 2024, 8:35 AM