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

auth.currentUser() returning user data after having logged out #229

Open
Miq3l opened this issue Nov 27, 2020 · 0 comments
Open

auth.currentUser() returning user data after having logged out #229

Miq3l opened this issue Nov 27, 2020 · 0 comments

Comments

@Miq3l
Copy link

Miq3l commented Nov 27, 2020

Describe the bug
Having 2 or more browser tabs opened, logging out form one of them, is removing the user object form the browser local storage. That's good, but...
When going back to the other opened tab, running the same webAPP, and calling auth.currentUser(), the function is returning the user data, for the logged out user.

The expected behavior would be gotrue-js to fetch the browser local storage, looking up for the user object, instead of returning data directly from the state store ( local vars).

To Reproduce

  1. Login in Gotrue-js
  2. open another browser tab running the same webapp
  3. Logout in one browser tab
  4. Go to the ohter tab and call auth.currentUser()
  5. User data is returned, despite of the user having logged out before and the user object, having been removed from the browser local storage.

This is happening with a webAPP (vue.js) running in Chrome.
Remember me param/setting set to true.

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

No branches or pull requests

1 participant