When I update firebase pods get this error:
Cannot convert value of type '(User?, Error?) -> ()' to expected argument type 'AuthDataResultCallback?' (aka 'Optional<(Optional, Optional) -> ()>')
static func signUp(username: String, email: String, User: String, Phone: String ,password: String, imageData: Data, onSuccess: @escaping () -> Void, onError: @escaping (_ errorMessage: String?) -> Void) {
Auth.auth().createUser(withEmail: email, password: password, completion: { (user: User?, error: Error?) in
if error != nil {
onError(error!.localizedDescription)
return
}
How can I fix this?
Auth.auth().createUser(withEmail: email, password: password, completion: { user, error in? - user9749232