diff --git a/src/app/posts.services.ts b/src/app/posts.services.ts index 812b1a2..0183bcf 100644 --- a/src/app/posts.services.ts +++ b/src/app/posts.services.ts @@ -734,7 +734,7 @@ export class PostsService implements CanActivate { this.afterLogin(res['user'], res['token'], res['permissions'], res['available_permissions']); } }, err => { - if (err.status === 401) { + if (err === 'Unauthorized') { this.sendToLogin(); this.token = null; this.resetHttpParams();