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

fix: improve expired token handling #148

Merged
merged 1 commit into from
Sep 17, 2024
Merged

Conversation

PurkkaKoodari
Copy link
Member

Fixes the regression from #141 where the app would redirect the user to the login page when opening it after inactivity, and improves handling of expired tokens.

  • The app no longer tries to renew expired tokens at all
  • Errors from token renewal are silently ignored, relying on the admin route requireAuth wrapper to trigger loginExpired when necessary

- Don't try to renew expired tokens at all
- Ignore renewal errors, show expiry toast via requireAuth instead
@PurkkaKoodari PurkkaKoodari added 🐛 bug Something isn't working 🖥️ frontend Relevant to the ilmomasiina-frontend package labels Sep 17, 2024
@PurkkaKoodari PurkkaKoodari requested a review from a team September 17, 2024 16:36
@PurkkaKoodari PurkkaKoodari merged commit 599fed2 into dev Sep 17, 2024
3 checks passed
@PurkkaKoodari PurkkaKoodari deleted the fix/renewing-expired-tokens branch September 17, 2024 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working 🖥️ frontend Relevant to the ilmomasiina-frontend package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants