Adjust checkAuthStatus timing and introduce reloadUsername on service initialization.
This commit is contained in:
parent
9ab0a130ed
commit
d69ef2cd20
|
|
@ -23,8 +23,10 @@ export class AuthService {
|
||||||
private snackBar: MatSnackBar
|
private snackBar: MatSnackBar
|
||||||
) {
|
) {
|
||||||
// Check if user is already logged in on service initialization
|
// Check if user is already logged in on service initialization
|
||||||
|
this.checkAuthStatus();
|
||||||
|
|
||||||
timer(1000).subscribe(() => {
|
timer(1000).subscribe(() => {
|
||||||
this.checkAuthStatus();
|
this.reloadUsername();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user