Skip to content

Commit

Permalink
chore(auth, ios): fix DLog formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
mikehardy committed May 20, 2024
1 parent fe7fdc3 commit c6ed777
Showing 1 changed file with 27 additions and 18 deletions.
45 changes: 27 additions & 18 deletions packages/auth/ios/RNFBAuth/RNFBAuthModule.m
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,9 @@ - (void)invalidate {
@"has expired or is not currently supported.",
}];
}
DLog(@"using app SignInWithCredential: %@", firebaseApp.name)[[FIRAuth authWithApp:firebaseApp]
DLog(@"using app SignInWithCredential: %@", firebaseApp.name);

[[FIRAuth authWithApp:firebaseApp]
signInWithCredential:credential
completion:^(FIRAuthDataResult *authResult, NSError *error) {
if (error) {
Expand Down Expand Up @@ -820,8 +822,9 @@ - (void)invalidate {
: (NSString *)phoneNumber
: (RCTPromiseResolveBlock)resolve
: (RCTPromiseRejectBlock)reject) {
DLog(@"SignInWthPhoneNumber instance: %@",
firebaseApp.name)[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
DLog(@"SignInWthPhoneNumber instance: %@", firebaseApp.name);

[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
verifyPhoneNumber:phoneNumber
UIDelegate:nil
completion:^(NSString *_Nullable verificationID, NSError *_Nullable error) {
Expand Down Expand Up @@ -862,8 +865,9 @@ - (void)invalidate {
}];
return;
}
DLog(@"using instance verifyPhoneNumberWithMultiFactorInfo: %@",
firebaseApp.name)[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
DLog(@"using instance verifyPhoneNumberWithMultiFactorInfo: %@", firebaseApp.name);

[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
verifyPhoneNumberWithMultiFactorInfo:hint
UIDelegate:nil
multiFactorSession:session
Expand Down Expand Up @@ -907,12 +911,15 @@ - (void)invalidate {
: (NSString *)verificationCode
: (RCTPromiseResolveBlock)resolve
: (RCTPromiseRejectBlock)reject) {
DLog(@"using instance resolve MultiFactorSignIn: %@", firebaseApp.name)
FIRPhoneAuthCredential *credential =
[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
credentialWithVerificationID:verificationId
verificationCode:verificationCode];
DLog(@"credential: %@", credential) FIRMultiFactorAssertion *assertion =
DLog(@"using instance resolve MultiFactorSignIn: %@", firebaseApp.name);

FIRPhoneAuthCredential *credential =
[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
credentialWithVerificationID:verificationId
verificationCode:verificationCode];
DLog(@"credential: %@", credential);

FIRMultiFactorAssertion *assertion =
[FIRPhoneMultiFactorGenerator assertionWithCredential:credential];

[cachedResolver[sessionKey] resolveSignInWithAssertion:assertion
Expand Down Expand Up @@ -955,11 +962,12 @@ - (void)invalidate {
: (NSString *_Nullable)displayName
: (RCTPromiseResolveBlock)resolve
: (RCTPromiseRejectBlock)reject) {
DLog(@"using instance finalizeMultifactorEnrollment: %@", firebaseApp.name)
FIRPhoneAuthCredential *credential =
[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
credentialWithVerificationID:verificationId
verificationCode:verificationCode];
DLog(@"using instance finalizeMultifactorEnrollment: %@", firebaseApp.name);

FIRPhoneAuthCredential *credential =
[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
credentialWithVerificationID:verificationId
verificationCode:verificationCode];
FIRMultiFactorAssertion *assertion =
[FIRPhoneMultiFactorGenerator assertionWithCredential:credential];
FIRUser *user = [FIRAuth authWithApp:firebaseApp].currentUser;
Expand All @@ -980,8 +988,9 @@ - (void)invalidate {
: (FIRApp *)firebaseApp
: (NSString *)phoneNumber
: (NSString *)requestKey) {
DLog(@"using instance verifyPhoneNumber: %@",
firebaseApp.name)[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
DLog(@"using instance verifyPhoneNumber: %@", firebaseApp.name);

[[FIRPhoneAuthProvider providerWithAuth:[FIRAuth authWithApp:firebaseApp]]
verifyPhoneNumber:phoneNumber
UIDelegate:nil
completion:^(NSString *_Nullable verificationID, NSError *_Nullable error) {
Expand Down

0 comments on commit c6ed777

Please sign in to comment.