Page MenuHomePhabricator

[lib] Update signatures in `thread-utils` to handle `MinimallyEncodedThreadInfo`
ClosedPublic

Authored by atul on Nov 13 2023, 2:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Oct 15 2024, 7:35 PM
Unknown Object (File)
Oct 15 2024, 1:19 AM
Unknown Object (File)
Oct 15 2024, 1:19 AM
Unknown Object (File)
Oct 15 2024, 1:19 AM
Unknown Object (File)
Oct 15 2024, 1:19 AM
Unknown Object (File)
Oct 15 2024, 1:14 AM
Unknown Object (File)
Sep 19 2024, 3:54 AM
Unknown Object (File)
Sep 14 2024, 5:09 PM
Subscribers
None

Details

Summary

Similar to D9811, we're updating utilities in thread-utils to handle MinimallyEncodedThreadInfo where the change is as simple as updating fn signature.

Will now go through and handle the ones that require more refactoring/branching/etc. Specifically:

  • threadUIName
  • checkIfDefaultMembers
  • patchThreadInfoToIncludeMentionedMembersOfParent
  • useRoleUserSurfacedPermissions

Depends on D9846

Test Plan

Entirely flow for now.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

lib/types/thread-types.js
51–55 ↗(On Diff #33150)

Spreading MemberInfo causes fields to being "writeable."

This became an issue because I wrapped type definition of MinimallyEncodedRelativeMemberInfo in $ReadOnly<> which caused some flow issues.

I figure this is more "correct" anyways given we prefer read-only where possible?

atul published this revision for review.Nov 13 2023, 2:15 PM
This revision is now accepted and ready to land.Nov 13 2023, 2:31 PM
This revision was landed with ongoing or failed builds.Nov 13 2023, 3:02 PM
This revision was automatically updated to reflect the committed changes.