Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Clients/Angular/finki-chattery/src/app/core/services/auth.service.ts

    rc205cc4 r59d860c  
    11import { Injectable } from '@angular/core';
    2 import { User, UserManager, WebStorageStateStore } from 'oidc-client';
     2import { User, UserManager } from 'oidc-client';
    33import { Observable, of } from 'rxjs';
    44
     
    1919    post_logout_redirect_uri: window.location.origin,
    2020    filterProtocolClaims: true,
    21     loadUserInfo: true,
    22     userStore: new WebStorageStateStore({ store: window.localStorage })
     21    loadUserInfo: true
    2322  });
    2423
     
    5554
    5655  public isStudent(): boolean {
    57     return this.user?.userType === ApplicationUserType.Student;
     56    return this.user !== null && this.user.userType === ApplicationUserType.Student;
    5857  }
    5958
Note: See TracChangeset for help on using the changeset viewer.