Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //вход
- [[FIRAuth auth] signInWithEmail:self.userNameTextField.text
- password:self.passwordTextField.text
- completion:^(FIRUser * _Nullable user, NSError * _Nullable error) {
- if (!error) {
- } else {
- NSLog(@"Error %@", error.localizedDescription);
- }
- }];
- //регистрация
- NSString *email = self.emailRegistrationTextField.text;
- NSString *password = self.passwordRegistrationTextField.text;
- [[FIRAuth auth] createUserWithEmail:email
- password:password
- completion:^(FIRUser * _Nullable user, NSError * _Nullable error) {
- if (!error) {
- self.fireUser = [[TSFireUser alloc] initWithDictionary:(NSDictionary *)user];
- } else {
- NSLog(@"Error - %@", error.localizedDescription);
- }
- }];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement