Created
November 30, 2016 21:34
-
-
Save jyaunches/6ddd423a09b1afa3ad2c0b7d3401d8a2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Auth0 | |
.authentication().createUser(email: email, | |
username: username, | |
password: "hellogrow", | |
connection: "Username-Password-Authentication", | |
userMetadata: [:]).start { result in | |
switch result { | |
case .success( _): | |
UserAuthenticationManager.sharedInstance.username = username | |
UserAuthenticationManager.sharedInstance.email = email | |
self.loginUser(email: email, onSuccess: onSuccess, onFailure: onFailure) | |
break | |
case .failure(let error): | |
self.handleError(error: error, onFailure: onFailure) | |
break | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment