diff --git a/frontend/src/ts/modules/security/guard/auth.guard.ts b/frontend/src/ts/modules/security/guard/auth.guard.ts index 992ca26..581218e 100644 --- a/frontend/src/ts/modules/security/guard/auth.guard.ts +++ b/frontend/src/ts/modules/security/guard/auth.guard.ts @@ -49,12 +49,21 @@ export abstract class AuthGuard implements CanActivate { params: params, responseType: 'text', observe: 'response', + headers: { + "Error-intercept-skip":"true" + } }) .toPromise() .then( () => { window.open(url.origin + url.pathname, "_self"); - }); + }) + .catch(reason => { + const json = JSON.parse(reason.error); + json.messages.forEach((errorMessage) => { + this.messageService.error(errorMessage, json); + }) + }); return false; } else {