File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
packages/auth/src/core/auth Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -78,6 +78,7 @@ export class AuthImpl implements AuthInternal, _FirebaseService {
78
78
private redirectPersistenceManager ?: PersistenceUserManager ;
79
79
private authStateSubscription = new Subscription < User > ( this ) ;
80
80
private idTokenSubscription = new Subscription < User > ( this ) ;
81
+ private beforeStateSubscription = new Subscription < User > ( this ) ;
81
82
private redirectUser : UserInternal | null = null ;
82
83
private isProactiveRefreshEnabled = false ;
83
84
@@ -371,6 +372,17 @@ export class AuthImpl implements AuthInternal, _FirebaseService {
371
372
) ;
372
373
}
373
374
375
+ beforeAuthStateChanged (
376
+ next : NextFn < User | null > ,
377
+ ) : Unsubscribe {
378
+ return this . registerStateListener (
379
+ this . beforeStateSubscription ,
380
+ next ,
381
+ error ,
382
+ completed
383
+ ) ;
384
+ }
385
+
374
386
onIdTokenChanged (
375
387
nextOrObserver : NextOrObserver < User > ,
376
388
error ?: ErrorFn ,
You can’t perform that action at this time.
0 commit comments