-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
137 auth service functionality #207
Conversation
…-auth-service-functionality
…oaWDCC/uasc-web into 137-auth-service-functionality
Co-authored-by: Logan <[email protected]>
…oaWDCC/uasc-web into 137-auth-service-functionality
Visit the preview URL for this PR (updated for commit 54d973e): https://uasc-ceebc--pr207-137-auth-service-fun-mm73tffn.web.app (expires Tue, 09 Apr 2024 10:09:47 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 36296ceaed1d43e92e7d5e81a72a7bd987560bfa |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, also I remembered what the custom claims meant in the ticket, it was to add functionality for adding claims given a uid, I can implement this if you want a break, but its pretty similar to what you've done here
…oaWDCC/uasc-web into 137-auth-service-functionality
…-auth-service-functionality
let userRecord: UserRecord | ||
try { | ||
userRecord = await auth.getUser(uid) | ||
auth.setCustomUserClaims(userRecord.uid, { [role]: true }) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: we should have the ability to remove the claim as well
No description provided.