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

Handle refresh offline #227

Closed
wants to merge 2 commits into from
Closed

Handle refresh offline #227

wants to merge 2 commits into from

Conversation

jake-nz
Copy link

@jake-nz jake-nz commented Feb 15, 2022

What kind of change does this PR introduce?

Bug fix

What is the current behavior?

Closes #226

What is the new behavior?

Does not try to refresh the token when offline, adds an event listener to refresh once online

Additional context

Happy to discuss alternatives. I needed to make this change for a project so I thought I'd contribute it here.

@hf
Copy link
Contributor

hf commented Feb 2, 2023

I'll close this PR because in v2 (I just merged) some code that allows you to call startAutoRefresh and stopAutoRefresh as you please. The online event is not perfect as it just means the computer is connected to a network, not that there is internet.

@hf hf closed this Feb 2, 2023
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

Successfully merging this pull request may close these issues.

Token refresh fails silently when offline and never recovers
2 participants