mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ACA-4322] Logout - Avoid the redirect in case SSO auth (#6780)
* Avoid the redirect in case of sso * Move the code into the if
This commit is contained in:
@@ -52,11 +52,7 @@ export class LogoutDirective implements OnInit {
|
||||
|
||||
getRedirectUri () {
|
||||
if (this.redirectUri === undefined ) {
|
||||
if (this.auth.isOauth()) {
|
||||
return this.appConfig.get<string>('oauth2.redirectUriLogout');
|
||||
} else {
|
||||
return this.appConfig.get<string>('loginRoute', '/login');
|
||||
}
|
||||
return this.appConfig.get<string>('loginRoute', '/login');
|
||||
}
|
||||
return this.redirectUri;
|
||||
}
|
||||
@@ -69,8 +65,8 @@ export class LogoutDirective implements OnInit {
|
||||
}
|
||||
|
||||
redirectToUri() {
|
||||
const redirectRoute = this.getRedirectUri();
|
||||
if (this.enableRedirect) {
|
||||
if (this.enableRedirect && !this.auth.isOauth()) {
|
||||
const redirectRoute = this.getRedirectUri();
|
||||
this.router.navigate([redirectRoute]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user