fix(auth, iOS): include missing email and credential in account-exists-with-different-credential error#17180
Merged
fix(auth, iOS): include missing email and credential in account-exists-with-different-credential error#17180
Conversation
…s-with-different-credential error
Contributor
Author
|
@Lyokone, I'm not sure how to write a test for this since the issue isn't reproducible against a Firebase Emulator instance. It only occurs when testing with a live project. Could you share your thoughts on how the test should be approached? |
Lyokone
reviewed
Mar 12, 2025
Comment on lines
-645
to
-647
| completion([PigeonParser getPigeonUserCredentialFromAuthResult:authResult | ||
| authorizationCode:nil], | ||
| nil); |
Contributor
There was a problem hiding this comment.
I see here that you have changed the order in completion, is this intentional?
Contributor
There was a problem hiding this comment.
My mistake it's because the whole indentation changed 😓
Comment on lines
-605
to
-607
| [auth signInWithCredential:credentials | ||
| completion:^(FIRAuthDataResult *authResult, NSError *error) { | ||
| if (error != nil) { |
Contributor
There was a problem hiding this comment.
The whole indentation changed because of this which makes reviewing harder, why formatting changed?
Lyokone
approved these changes
Mar 12, 2025
MichaelVerdon
approved these changes
Apr 10, 2025
ohhyungkwon
reviewed
Apr 15, 2025
| NSString *errorCode = userInfo[@"FIRAuthErrorUserInfoNameKey"]; | ||
|
|
||
| if (firebaseDictionary == nil && errorCode != nil) { | ||
| if ([errorCode isEqual:@"ERROR_ACCOUNT_EXISTS_WITH_DIFFERENT_CREDENTIAL"]) { |
There was a problem hiding this comment.
Can we compare error.code with FIRAuthErrorCodeAccountExistsWithDifferentCredential?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes missing email and credential properties in account-exists-with-different-credential error on iOS
Related Issues
Fixes #17160
Checklist
Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes (
[x]).This will ensure a smooth and quick review process. Updating the
pubspec.yamland changelogs is not required.///).melos run analyze) does not report any problems on my PR.Breaking Change
Does your PR require plugin users to manually update their apps to accommodate your change?