[auth] Support email link in checkActionCode

This commit is contained in:
Chris Bianca 2018-05-16 12:41:48 +01:00
parent 35474462c6
commit 34c0878098
2 changed files with 6 additions and 0 deletions

View File

@ -1023,6 +1023,9 @@ class RNFirebaseAuth extends ReactContextBaseJavaModule {
case ActionCodeResult.PASSWORD_RESET: case ActionCodeResult.PASSWORD_RESET:
actionType = "PASSWORD_RESET"; actionType = "PASSWORD_RESET";
break; break;
case ActionCodeResult.SIGN_IN_WITH_EMAIL_LINK:
actionType = "EMAIL_SIGNING";
break;
} }
writableMap.putString("actionType", actionType); writableMap.putString("actionType", actionType);

View File

@ -680,6 +680,9 @@ RCT_EXPORT_METHOD(checkActionCode:
case FIRActionCodeOperationRecoverEmail: case FIRActionCodeOperationRecoverEmail:
actionType = @"RECOVER_EMAIL"; actionType = @"RECOVER_EMAIL";
break; break;
case FIRActionCodeOperationEmailLink:
actionType = @"EMAIL_SIGNIN";
break;
} }
NSDictionary *result = @{@"data": @{@"email": [info dataForKey:FIRActionCodeEmailKey], @"fromEmail": [info dataForKey:FIRActionCodeFromEmailKey],}, @"actionType": actionType,}; NSDictionary *result = @{@"data": @{@"email": [info dataForKey:FIRActionCodeEmailKey], @"fromEmail": [info dataForKey:FIRActionCodeFromEmailKey],}, @"actionType": actionType,};