Is your feature request related to a problem? Please describe.
Currently we have two ways of identifying the user's membership, one through their JWT token (firestore claims), the other through a property called membership in the Users collection.
The one in the Users collection serves no purpose and should therefore be removed.
The first thing to do is remove the membership property from UserAdditionalInfo in server\src\data-layer\models\firebase.ts
It is recommended to use a search feature in your IDE to find usages of membership. Tests relating to membership should be deleted, as well as any calls to UserService in the controllers folder that use it. The mocks in User.mock.ts (server\src\test-config\mocks\User.mock.ts) will also need to be updated.
BEFORE MERGING
Is your feature request related to a problem? Please describe. Currently we have two ways of identifying the user's membership, one through their JWT token (firestore claims), the other through a property called
membership
in theUsers
collection.The one in the
Users
collection serves no purpose and should therefore be removed.The first thing to do is remove the
membership
property fromUserAdditionalInfo
inserver\src\data-layer\models\firebase.ts
It is recommended to use a search feature in your IDE to find usages of
membership
. Tests relating tomembership
should be deleted, as well as any calls toUserService
in thecontrollers
folder that use it. The mocks inUser.mock.ts
(server\src\test-config\mocks\User.mock.ts
) will also need to be updated. BEFORE MERGINGyarn workspace server tsoa spec-and-routes
)git fetch origin master:master
, thengit rebase master
orgit merge master
)