Closed frizzo closed 7 years ago
Without this change the authenticated
method does not detect when the user is already logged in if/when the app is restarted:
https://github.com/auth0-samples/auth0-ionic2-samples/blob/master/01-Login/src/services/auth/auth.service.ts#L49
The getUserInfo
method does rely on this.accessToken
but getUserInfo
is only called in the authenticated
callback and that callback sets accessToken
:
https://github.com/auth0-samples/auth0-ionic2-samples/blob/master/01-Login/src/services/auth/auth.service.ts#L49
ah I see what you're saying. yes, that makes sense. thanks for clarifying 👍
@saschwarz thanks for explaining the issue
Thanks for your PR :)
This actually needs to be the
accessToken
instead of theidToken
. ThegetUserInfo
method relies on that.What was the problem the
accessToken
caused in your case?