Skip to content
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

Allow claims to be persited on the user so claims perists through token refresh #4

Open
dmlayton opened this issue Sep 22, 2021 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@dmlayton
Copy link
Collaborator

return await admin.auth().createCustomToken(account, claims); puts the claims on the token but does save them to the user.
So when the browser refreshes the user's token, they lose these claims until they log back in (which currently requires them to sign another message).

This raises some UX questions around waiting for lock purchases to hit the blockchain.

Saving claims to the User should be the default, but configurable. Should we wrap a method for the browser to request a claims update on the (logged-in) user (and refresh the token if changed)? What are some other approaches? Messaging? We want to avoid requiring the app use RT database and/or Firestore. KISS

@dmlayton dmlayton added the enhancement New feature or request label Sep 22, 2021
@dmlayton dmlayton self-assigned this Sep 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant