Page MenuHomePhabricator

[keyserver] Update role-creator to include specialRole field

Authored by atul on Nov 30 2023, 1:11 PM.
Referenced Files
Unknown Object (File)
Fri, Feb 23, 11:23 PM
Unknown Object (File)
Fri, Feb 23, 10:26 PM
Unknown Object (File)
Fri, Feb 23, 9:42 PM
Unknown Object (File)
Fri, Feb 23, 12:45 PM
Unknown Object (File)
Thu, Feb 22, 11:31 AM
Unknown Object (File)
Thu, Feb 22, 11:30 AM
Unknown Object (File)
Wed, Feb 21, 12:31 PM
Unknown Object (File)
Wed, Feb 21, 12:16 PM



There are some places in the codebase that we hardcode isDefault. Here, we'll want to introduce the specialRole field alongside, so when we deprecate isDefault, no additional changes will be needed. Some are important (like one instance in thread-utils.js and the instance in role-creator.js where we set up initial roles for threads), and others are just test data. Nonetheless, I thought I may as well update all of them for consistency.

Part of ENG-5993

This diff handles role-creator.js

Depends on D10107

Test Plan

Right now, just flow to make sure we didn't violate the type. Further testing can be done once isDefault is removed

Diff Detail

rCOMM Comm
Lint Not Applicable
Tests Not Applicable

Event Timeline

rohan held this revision as a draft.
rohan published this revision for review.Nov 30 2023, 1:33 PM
This revision is now accepted and ready to land.Dec 1 2023, 7:55 AM
atul edited reviewers, added: rohan; removed: atul.


767 ↗(On Diff #36886)

This should not have been staged, this was from testing another diff. Will update

This should be safe to land on its own:

  1. createInitialRolesForNewThread() is only called by createThread() in thread-creator
  2. The only fields accessed are and, so nothing changes here
This revision was landed with ongoing or failed builds.Thu, Feb 8, 1:37 PM
This revision was automatically updated to reflect the committed changes.