Fix unused variable in app.component.ts
This commit is contained in:
parent
17b662568c
commit
b36c886068
|
@ -8,7 +8,9 @@ import { Router, NavigationEnd } from '@angular/router'
|
||||||
export class LocationBackService {
|
export class LocationBackService {
|
||||||
private history: string[] = [];
|
private history: string[] = [];
|
||||||
|
|
||||||
constructor(private router: Router, private location: Location) {
|
constructor(private router: Router, private location: Location) { }
|
||||||
|
|
||||||
|
initialize() {
|
||||||
this.router.events.subscribe((event) => {
|
this.router.events.subscribe((event) => {
|
||||||
if (event instanceof NavigationEnd && !event.urlAfterRedirects.includes('login')) {
|
if (event instanceof NavigationEnd && !event.urlAfterRedirects.includes('login')) {
|
||||||
this.history.push(event.urlAfterRedirects);
|
this.history.push(event.urlAfterRedirects);
|
||||||
|
|
|
@ -32,6 +32,7 @@ export class AppComponent {
|
||||||
public guard: AuthorizeGuard
|
public guard: AuthorizeGuard
|
||||||
) {
|
) {
|
||||||
this.revision_datetime_string = new Date(versions.revision_timestamp).toLocaleString(undefined, { day: '2-digit', month: '2-digit', year: 'numeric', hour: 'numeric', minute: 'numeric', second: 'numeric' });
|
this.revision_datetime_string = new Date(versions.revision_timestamp).toLocaleString(undefined, { day: '2-digit', month: '2-digit', year: 'numeric', hour: 'numeric', minute: 'numeric', second: 'numeric' });
|
||||||
|
this.locationBackService.initialize();
|
||||||
}
|
}
|
||||||
|
|
||||||
loadAlerts() {
|
loadAlerts() {
|
||||||
|
|
Loading…
Reference in New Issue