Page MenuHomePhabricator

[lib] add action to set users device lists in `AuxUserStore`
ClosedPublic

Authored by kamil on Apr 30 2024, 6:52 AM.
Tags
None
Referenced Files
F3386624: D11841.diff
Fri, Nov 29, 5:25 AM
F3383619: D11841.diff
Thu, Nov 28, 5:00 PM
Unknown Object (File)
Sun, Nov 24, 2:53 PM
Unknown Object (File)
Sat, Nov 23, 5:44 PM
Unknown Object (File)
Tue, Nov 12, 12:26 PM
Unknown Object (File)
Tue, Nov 12, 12:23 PM
Unknown Object (File)
Tue, Nov 12, 11:51 AM
Unknown Object (File)
Mon, Nov 11, 7:03 PM
Subscribers

Details

Summary

ENG-7394.

Adding action to set device lists of multiple users.

Depends on D11840

Test Plan

Tests

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.May 6 2024, 4:25 AM
lib/actions/aux-user-actions.js
7

Should this be read as "set users' device lists"? I wonder if SET_PEER_DEVICE_LISTS would be more clear

tomek added inline comments.
lib/reducers/aux-user-reducer.js
92–94

Why do we have to handle fid in a special way?

94

I think it might be slightly more readable to have a property inside a payload where we have an object with device lists.

This revision is now accepted and ready to land.May 7 2024, 2:43 AM
  • add property inside payload
  • SET_USERS_DEVICE_LISTS -> SET_PEER_DEVICE_LISTS
lib/actions/aux-user-actions.js
7

Should this be read as "set users' device lists"?

yes, that was my intention

I wonder if SET_PEER_DEVICE_LISTS would be more clear

agree with that

lib/reducers/aux-user-reducer.js
92–94

Why do we have to handle fid in a special way?

According to type definition fid is nullable but the field itself should be defined. That being said when adding a peer list to userID that wasn't previously in AuxUserStore we need to do it this way