Skip to content

Update LoggedInOutlet.ts #49

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

Merged
merged 1 commit into from
Mar 27, 2016
Merged

Update LoggedInOutlet.ts #49

merged 1 commit into from
Mar 27, 2016

Conversation

MasterKale
Copy link
Contributor

  • Updated activate() to handle a bug that enabled access to non-public routes after loading a public route
  • Updated publicRoutes to reflect values returned by ComponentInstruction.urlPath
  • Added a small comment clarifying the purpose of the boolean assigned to each route in publicRoutes

- Updated `activate()` to handle a bug that enabled access to non-public routes after loading a public route
- Updated `publicRoutes` to reflect values returned by `ComponentInstruction.urlPath`
- Added a small comment clarifying the purpose of the boolean assigned to each route in `publicRoutes`
@MasterKale
Copy link
Contributor Author

I discovered an issue in LoggedInOutlet that allowed you to load a non-public route after loading a public route. To recreate the issue, load the /login route and then change the URL in the address bar and go to /home. The /home route will load because this.parentRouter.lastNavigationAttempt will return /login, which IS a public route.

Calling instance.urlPath will return the route that is currently being navigated to and will redirect accordingly if the route is not in publicRoutes.

@ojacquemart
Copy link

👍, I noticed the same issue.

@chenkie chenkie merged commit 91f67a3 into auth0-blog:master Mar 27, 2016
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.

3 participants