Skip to content

Strange problem with "authenticate" route check client-side #348

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

Closed
f2net opened this issue Jul 14, 2014 · 2 comments
Closed

Strange problem with "authenticate" route check client-side #348

f2net opened this issue Jul 14, 2014 · 2 comments

Comments

@f2net
Copy link

f2net commented Jul 14, 2014

If I set the authenticate flag on a route, when I am logged I see that everything works as expected if I reach the route through a link, while, if I enter the URL directly, it sends me to the login page, because here

if (next.authenticate && !Auth.isLoggedIn()) {

Auth.isLoggedIn() return false, as if the currentUser had not the "role" property set.

I cannot reproduce this error on the demo because it relies only on the server-side 401 to authenticate, without setting the "authenticate" flag on the restricted routes.

Thank you,
Matteo

@DaftMonk
Copy link
Member

I haven't released a new version yet, but this commit should fix that issue. 6d6090d

@DaftMonk
Copy link
Member

2.0.5 should fix this. If it doesn't, let me know and I'll reopen this issue.

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