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

Setting persistSession: false still persists auth session #390

Open
AccountingSystems opened this issue Jul 14, 2024 · 0 comments
Open

Setting persistSession: false still persists auth session #390

AccountingSystems opened this issue Jul 14, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@AccountingSystems
Copy link

I don't want to persist the auth session in my project, so in my nuxt.config.ts I set persistSession: false. But the auth session still persists and I can retrieve it when I try to get the current user await useSupabaseClient().auth.getUser()

Version

@nuxtjs/supabase:
nuxt:

Steps to reproduce

  1. Create a new project with the specified dependency versions
  2. Set your supabase section in nuxt.config.ts to
supabase: {
    cookieOptions: {
      secure: process.env.NODE_ENV === "production",
    },
    clientOptions: {
      auth: {
        persistSession: false,
      },
    },
  }
  1. Sign in
  2. close the website
  3. re-open the website
  4. Check for authentication status

What is Expected?

The authentication state is clear and no session or user currently exists/authenticated

What is actually happening?

The previously signed in user is authenticated and can be retrieved from the supabase client.

@AccountingSystems AccountingSystems added the bug Something isn't working label Jul 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant