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

Auth Code Grant Callback is async and can "race" with later getTokens. #103

Open
BusterNeece opened this issue Sep 12, 2019 · 0 comments
Open

Comments

@BusterNeece
Copy link

I noticed this project's implementation of the authorization code grant is in "beta" status, but I did notice one particular issue: because it uses the Fetch API to pull the access token from the auth code, this request happens asynchronously, meaning it's entirely possible (and likely, even) that a later call to getToken on the same page will show that no token exists, because the initial auth token request hasn't had a chance to finish.

It could be that the addition of await to the Fetch calls in the auth code grant handler could resolve the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant