fixed the redirect to the login in case of security layer enabled

This commit is contained in:
Fabio Formosa
2022-11-19 12:18:36 +01:00
parent b20fb9e9c3
commit bd5276116b
2 changed files with 6 additions and 5 deletions

View File

@@ -42,8 +42,9 @@ export class UserService {
this.router.initialNavigation();
return;
}
if (httpErrorResponse.status < 200 || httpErrorResponse.status > 399)
if (httpErrorResponse.status !== 401 && (httpErrorResponse.status < 200 || httpErrorResponse.status > 399)) {
this.router.navigateByUrl('/error');
}
});
}

View File

@@ -31,10 +31,10 @@
<groupId>it.fabioformosa.quartz-manager</groupId>
<artifactId>quartz-manager-starter-ui</artifactId>
</dependency>
<!-- <dependency>-->
<!-- <groupId>it.fabioformosa.quartz-manager</groupId>-->
<!-- <artifactId>quartz-manager-starter-security</artifactId>-->
<!-- </dependency>-->
<dependency>
<groupId>it.fabioformosa.quartz-manager</groupId>
<artifactId>quartz-manager-starter-security</artifactId>
</dependency>
<!-- <dependency>-->
<!-- <groupId>it.fabioformosa.quartz-manager</groupId>-->
<!-- <artifactId>quartz-manager-starter-persistence</artifactId>-->