mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
71201: #678 Angular UI does not properly logout when clicking logout
This commit is contained in:
@@ -221,7 +221,7 @@ export class AuthInterceptor implements HttpInterceptor {
|
|||||||
// Redirect to the login route
|
// Redirect to the login route
|
||||||
this.store.dispatch(new RedirectWhenTokenExpiredAction('auth.messages.expired'));
|
this.store.dispatch(new RedirectWhenTokenExpiredAction('auth.messages.expired'));
|
||||||
return observableOf(null);
|
return observableOf(null);
|
||||||
} else if (!this.isAuthRequest(req) && isNotEmpty(token)) {
|
} else if ((!this.isAuthRequest(req) || this.isLogoutResponse(req)) && isNotEmpty(token)) {
|
||||||
// Intercept a request that is not to the authentication endpoint
|
// Intercept a request that is not to the authentication endpoint
|
||||||
authService.isTokenExpiring().pipe(
|
authService.isTokenExpiring().pipe(
|
||||||
filter((isExpiring) => isExpiring))
|
filter((isExpiring) => isExpiring))
|
||||||
|
Reference in New Issue
Block a user