Skip to content

Commit

Permalink
chore(auth): add console warning to notify of breaking getAuth change
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffbcross committed Jun 21, 2016
1 parent 4b17f0a commit 022e50c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/providers/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,10 @@ export class AngularFireAuth extends ReplaySubject<FirebaseAuthState> {
}

public getAuth(): FirebaseAuthState {
console.warn(`WARNING: the getAuth() API has changed behavior since adding support for Firebase 3.
This will return null for the initial value when the page loads, even if the user is actually logged in.
Please observe the actual authState asynchronously by subscribing to the auth service: af.auth.subscribe().
The getAuth method will be removed in future releases`);
return this._authBackend.getAuth()
}

Expand Down

0 comments on commit 022e50c

Please sign in to comment.