Skip to content

Commit

Permalink
fix(auth): use onAuthStateChanged for authState (#2308)
Browse files Browse the repository at this point in the history
  • Loading branch information
sarunint authored Feb 5, 2020
1 parent 0ae30d8 commit 9506f85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/auth/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export class AngularFireAuth {
});

this.authState = new Observable<User | null>(subscriber => {
return zone.runOutsideAngular(() => this.auth.onIdTokenChanged(subscriber));
return zone.runOutsideAngular(() => this.auth.onAuthStateChanged(subscriber));
}).pipe(keepUnstableUntilFirst);;

this.user = new Observable<User | null>(subscriber => {
Expand Down

0 comments on commit 9506f85

Please sign in to comment.