Skip to content

Conversation

@JoelWiebe
Copy link
Contributor

Completed

  • Extended session duration from 2h to 4h
  • Modified API Interceptor to navigate to login page on 401 error
  • Modified invalid token error to throw 401 error

Test

  • Verify no unusual browser console or backend errors (other than the one or two 401 errors thrown immediately at the time a resource is requested when the session token has expired)
  • Ensure navigation is routed to the login page when the session expires and a resource is requested

To test, you may need to rebuild the backend and it will be helpful to adjust the session token duration

  • Search all files and replace three instances of '4h' with '1m' so that the session will expire after 1 minute
  • In backend perform: "rm -r node_modules; npm install; npm run dev" to rebuild
  • Login and wait for just over a minute, then attempt to navigate to another page or create a post
  • You should be navigated back to the login page with a 401 error

Closes #651

…navigate to login page on 401 error; Modified invalid token error to throw 401 error
@JoelWiebe JoelWiebe linked an issue Jan 25, 2025 that may be closed by this pull request
2 tasks
Copy link
Contributor

@markiianbabiak markiianbabiak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot 2025-02-03 at 2 45 25 AM This is the page I got instead of the login page.

To recreate:
Login, go to any board, go to canvas, wait, try switching to workspace.

Side note: consider also showing a pop-up message at the top saying "Session expired. Redirected to login page"

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.

FEATURE: Session expiration redirect to login page

3 participants