Skip to content

Instantly share code, notes, and snippets.

@CurtisHumphrey
Created March 2, 2015 16:13
Show Gist options
  • Save CurtisHumphrey/5dd6fa55c2674ae03bc6 to your computer and use it in GitHub Desktop.
Save CurtisHumphrey/5dd6fa55c2674ae03bc6 to your computer and use it in GitHub Desktop.
example from if-firebase-auth
login: function(user) {
return $q(function(resolve, reject) {
BACKEND.authWithPassword(user, function(error, authData) {
if (error === null) {
// user authenticated with Firebase
getUserData(authData);
temporaryPassword = authData.password.isTemporaryPassword;
authServiceError = {};
resolve('logged in');
} else {
authServiceError = error;
reject(error);
}
});
});
},
@CurtisHumphrey
Copy link
Author

I had not seen "authData.password.isTemporaryPassword" before in the Firebase Docs. Found it not in the API but in the guide: https://www.firebase.com/docs/web/guide/login/password.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment