Skip to content

Commit 0836a95

Browse files
authored
fix(auth): ios providerData properties undefined (#145)
1 parent 162e9d8 commit 0836a95

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

packages/firebase-auth/index.ios.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,27 +80,27 @@ export class UserInfo implements IUserInfo {
8080
}
8181

8282
get uid(): string {
83-
return this.native?.uid;
83+
return this.native?.valueForKey("uid");
8484
}
8585

8686
get displayName(): string {
87-
return this.native?.displayName;
87+
return this.native?.valueForKey("displayName");
8888
}
8989

9090
get email(): string {
91-
return this.native?.email;
91+
return this.native?.valueForKey("email");
9292
}
9393

9494
get phoneNumber(): string {
95-
return this.native?.phoneNumber;
95+
return this.native?.valueForKey("phoneNumber");
9696
}
9797

9898
get photoURL(): string {
99-
return this.native?.photoURL?.absoluteString;
99+
return this.native?.valueForKey("photoURL")?.absoluteString;
100100
}
101101

102102
get providerId(): string {
103-
return this.native?.providerID;
103+
return this.native?.valueForKey("providerID");
104104
}
105105

106106
toJSON() {

packages/firebase-auth/typings/objc!FirebaseAuth.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -829,7 +829,7 @@ declare class FIRUser extends NSObject implements FIRUserInfo {
829829
updatePhoneNumberCredentialCompletion(phoneNumberCredential: FIRPhoneAuthCredential, completion: (p1: NSError) => void): void;
830830
}
831831

832-
interface FIRUserInfo extends NSObjectProtocol {
832+
interface FIRUserInfo extends NSObject {
833833

834834
displayName: string;
835835

0 commit comments

Comments
 (0)