SUPPORT-8897: Fix
This commit is contained in:
parent
07b26219a7
commit
e1f155971c
1 changed files with 3 additions and 4 deletions
|
|
@ -2,7 +2,7 @@ import {Injectable} from "@angular/core";
|
|||
import {ActivatedRouteSnapshot, CanActivate, Router, RouterStateSnapshot} from "@angular/router";
|
||||
import {Observable} from "rxjs";
|
||||
import {HttpClient, HttpParams} from "@angular/common/http";
|
||||
import {MessagesService, ErrorMessageService} from "@webbpm/base-package";
|
||||
import {MessagesService} from "@webbpm/base-package";
|
||||
import {AuthenticationService} from "../authentication.service";
|
||||
import {EsiaErrorDetail} from "../EsiaErrorDetail";
|
||||
|
||||
|
|
@ -13,8 +13,7 @@ export abstract class AuthGuard implements CanActivate {
|
|||
protected router: Router,
|
||||
private httpClient: HttpClient,
|
||||
private authenticationService: AuthenticationService,
|
||||
private messageService: MessagesService,
|
||||
private errorMessageService: ErrorMessageService
|
||||
private messageService: MessagesService
|
||||
) {
|
||||
}
|
||||
|
||||
|
|
@ -49,7 +48,7 @@ export abstract class AuthGuard implements CanActivate {
|
|||
? reason.error.messages
|
||||
: reason.error.replaceAll('\\', '');
|
||||
if (error) {
|
||||
errorMessage = this.errorMessageService.getErrorMessage();
|
||||
errorMessage = this.messageService.getUnknowErrorMessage();
|
||||
let errorCode = this.extractCode(errorDescription);
|
||||
if (errorCode) {
|
||||
errorMessage = EsiaErrorDetail.getDescription(errorCode);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue