File tree 2 files changed +16
-10
lines changed
2 files changed +16
-10
lines changed Original file line number Diff line number Diff line change @@ -1695,6 +1695,7 @@ - (NSDictionary *)firebaseUserToDict:(FIRUser *)user {
1695
1695
@" enrollmentTime" : enrollmentTime,
1696
1696
// @deprecated enrollmentDate kept for backwards compatibility, please use enrollmentTime
1697
1697
@" enrollmentDate" : enrollmentTime,
1698
+ @" phoneNumber" : hint.phoneNumber ,
1698
1699
}];
1699
1700
}
1700
1701
return enrolledFactors;
Original file line number Diff line number Diff line change @@ -472,7 +472,21 @@ export namespace FirebaseAuthTypes {
472
472
/**
473
473
* Contains information about a second factor.
474
474
*/
475
- export interface MultiFactorInfo {
475
+ export type MultiFactorInfo = PhoneMultiFactorInfo | TotpMultiFactorInfo ;
476
+
477
+ export interface PhoneMultiFactorInfo extends MultiFactorInfoCommon {
478
+ factorId : 'phone' ;
479
+ /**
480
+ * The phone number used for this factor.
481
+ */
482
+ phoneNumber : string ;
483
+ }
484
+
485
+ export interface TotpMultiFactorInfo extends MultiFactorInfoCommon {
486
+ factorId : 'totp' ;
487
+ }
488
+
489
+ export interface MultiFactorInfoCommon {
476
490
/**
477
491
* User friendly name for this factor.
478
492
*/
@@ -481,21 +495,12 @@ export namespace FirebaseAuthTypes {
481
495
* Time the second factor was enrolled, in UTC.
482
496
*/
483
497
enrollmentTime : string ;
484
- /**
485
- * Type of factor.
486
- */
487
- factorId : FactorId ;
488
498
/**
489
499
* Unique id for this factor.
490
500
*/
491
501
uid : string ;
492
502
}
493
503
494
- export interface PhoneMultiFactorInfo extends MultiFactorInfo {
495
- factorId : "phone" ;
496
- phoneNumber : string ;
497
- }
498
-
499
504
export interface MultiFactorAssertion {
500
505
token : string ;
501
506
secret : string ;
You can’t perform that action at this time.
0 commit comments