Skip to content

Authenticated users redirected to login page while session is being re-fetched #621

Open
@VeeBack

Description

@VeeBack

Environment

No response

Reproduction

No response

Describe the bug

With enableRefreshPeriodically enabled, while the session is being fetched the authenticated state is set to "loading". This means that when the middleware check happens, since it checks for the state to be "authenticated", it gets treated as the user is unauthenticated while the data is being fetched.

If the user attempts to navigate to another page, during the time the session is in the process of being re-fetched, they are sent to the login page.

Additional context

No response

Logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    1.0bugA bug that needs to be resolvedp4Important Issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions