-
Notifications
You must be signed in to change notification settings - Fork 153
fix(AccessToken): Added token query based on $location.path() #48
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
Conversation
fix(AccessToken): Added token query based on $location.path()
|
Thanks a lot! |
|
👍 👏 |
|
This broke the plugin for me. Access token is in the |
|
Yes. It broke also the code I've tested this morning. I have no idea on why
|
|
Ok, so it is not just me :). It is a pitty that this got merged and released. I am missing any kind of description for the "fix" (what use-case is this supposed to fix). |
|
v0.2.9 removed as suggested. I'm sorry for this, but all tests were passing. I would love to investigate, but no time right now. @pavelhoral, can you help me in this. It would be really nice. |
|
Tests were not failing because the change was only in the |
|
Sorry y'all, moving quick to squash production issues on my end, and completely side stepped protocol. $location.hash() was returning nothing. Using $location.path().substr(1) in theory is the same thing and this would give me the hash value/ access token. |
No, it does not return the same thing - $location behaves differently depending on HTML5 mode (i.e. whether the path is based on the hash or not). Please check the documentation. For non-HTML5 mode you need to register special route. |
|
Yep, I did check the docs. Correct me if I'm wrong, the docs say to use AccessToken.setTokenFromString() which is no longer a public function: https://github.com/andreareginato/oauth-ng/blob/master/app/scripts/services/access-token.js#L65 |
|
Looks like there is a PR to make AccessToken.setTokenFromString() public again: |
|
Guys. I merged #49. Still not compiled in dist, but I'm gonna do it pretty soon hoping this solves everything. I'm wondering if we should make a better test suite to avoid this same problem next time. |
No description provided.