@H_404_7@解决方法
原文链接:https://www.f2er.com/iOS/333045.html
在更改密码之前,您将能够使用
reauthenticate实现它.
let user = FIRAuth.auth()?.currentUser let credential = FIREmailPasswordAuthProvider.credentialWithEmail(email,password: currentPassword) user?.reauthenticateWithCredential(credential,completion: { (error) in if error != nil{ self.displayAlertMessage("Error reauthenticating user") }else{ //change to new password } })