diff --git a/src/app/authentication/authentication.component.ts b/src/app/authentication/authentication.component.ts index d7072d7..e602c8e 100644 --- a/src/app/authentication/authentication.component.ts +++ b/src/app/authentication/authentication.component.ts @@ -54,6 +54,7 @@ export class AuthenticationComponent implements OnInit { localStorage.removeItem('gen_name'); localStorage.removeItem('data_type'); localStorage.removeItem('fault_type'); + localStorage.removeItem('auth_token'); } } diff --git a/src/app/header/header.component.ts b/src/app/header/header.component.ts index 9c640f5..20b222c 100644 --- a/src/app/header/header.component.ts +++ b/src/app/header/header.component.ts @@ -25,7 +25,7 @@ export class HeaderComponent implements OnInit { } isLoggedIn() { - if(this.router.url != '/' && this.router.url != '/#') + if(localStorage.getItem('auth_token')) { return true; }