Reputation: 8935
I am using AngularFire2 to authenticate users with Firebase.
I am allowing the user to change their email address.
firebaseUser: firebase.User
firebaseUser.updateEmail(newEmail).catch((data) => {...
Now I would like to also be able to set the emailVerification
to false
.
firebaseUser.emailVerified = false;
Does the updateEmail
function automatically set it to false, or is it something I need to manually do? If so, how?
Any help appreciated.
Upvotes: 0
Views: 868
Reputation: 9517
At the moment, here's how I believe it works (I stand to be corrected)
According to the docs, when you update an email with a new email, here's what happens:
"An email will be sent to the original email address (if it was set) that allows to revoke the email address change, in order to protect them from account hijacking."
Upon confirmation (here's the part I'm not certain), the new email is set as emailVerified: false
, because well the email that was verified is gone.
Therefore, if you would wanna have this new email address verified, then please resend a verification for that too.
Upvotes: 1