فهرست منبع

fix: simplify logout method by removing unnecessary subscription

EmilianoChavarria 3 هفته پیش
والد
کامیت
994b1419fd
1فایلهای تغییر یافته به همراه2 افزوده شده و 7 حذف شده
  1. 2 7
      Front/src/app/shared/navbar-home/navbar-home.component.ts

+ 2 - 7
Front/src/app/shared/navbar-home/navbar-home.component.ts

@@ -195,13 +195,8 @@ export class NavbarHomeComponent implements OnInit {
 
 
   logout() {
-    this.authService.logout().subscribe((response) => {
-      localStorage.clear();
-      this._router.navigate(['']);
-    },
-      (err) => {
-      }
-    );
+    localStorage.clear();
+    this._router.navigate(['']);
   }
 
   checkUrl() {