Page MenuHomePhabricator

[lib] refactor `createOlmSessionWithPeer` -> `createOlmSessionsWithUser` in `PeerOlmSessionCreatorContextType`
ClosedPublic

Authored by kamil on Sep 18 2024, 5:01 AM.
Tags
None
Referenced Files
F3535782: D13372.id44332.diff
Wed, Dec 25, 4:53 PM
F3535780: D13372.id44325.diff
Wed, Dec 25, 4:53 PM
F3535777: D13372.id44290.diff
Wed, Dec 25, 4:53 PM
F3535742: D13372.id.diff
Wed, Dec 25, 4:52 PM
F3535739: D13372.diff
Wed, Dec 25, 4:52 PM
Unknown Object (File)
Mon, Dec 16, 12:12 PM
Unknown Object (File)
Thu, Dec 12, 6:56 AM
Unknown Object (File)
Thu, Nov 28, 11:13 PM
Subscribers

Details

Summary

ENG-9106.

Update context to support multiple devices.

Callsites are updated later in the stack.

Depends on D13371.

Test Plan

Tested in D13376

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.
kamil published this revision for review.Sep 18 2024, 5:42 AM
kamil edited the test plan for this revision. (Show Details)
tomek added inline comments.
lib/components/peer-olm-session-creator-provider.react.js
42–62 ↗(On Diff #44290)

This is a little fragile because when this function is called for different devices and the promise is still pending, we would return an existing promise. To fix this issue we should restore the promises map, assign the same promise to all the devices, and return Promise.all of all the promises associated with devices.

This revision is now accepted and ready to land.Sep 18 2024, 7:54 AM