-
Notifications
You must be signed in to change notification settings - Fork 153
Description
Hello,
I am building a single page app where you need to be logged in on every page. So on every one of my route I check if the AccessToken has been set, otherwise I redirect to the Oauth login page using the EndPoint service. After being logged, when I am redirected towards my app I have a route for retrieving the accessToken that set it to the AccessToken with AccessToken.setTokenFromString(token) as described on your webpage.
So I never really use the "sign-in" button. But I want to use the "logout" button.
On logout, I want to add the redirection towards the logout url. So I thought I was going to listen the the logout event and do a $location.path(myLougoutUrl);
Problem is the logout event is fired inside the initView() method. So after loggin, I am redirected towards my app that send the logout event at initialization then as I listen to that event then I am redirected towards the logout url automatically :(
I think logout event should NOT be fired inside initView()
I hope I was clear enough. Maybe this can be merged with issue about adding logout url
P.S. Thx for the lib :)