iOS Question Firebase/ Facebook Authentication

Marcos Alves

Well-Known Member
Licensed User
Hello all,

using Firebase Authentication/Facebook I'm getting the problem as follows:

- I'm giving to the user the option to use FaceBook OR Google authetication
- If I authenticated an user/email using Google, when I try to register again using FB Firebase raises the error message:

Error signing in: Error Domain=FIRAuthErrorDomain Code=17012 "An account already exists with the same email address but different sign-in credentials. Sign in using a provider associated with this email address." UserInfo={FIRAuthErrorUserInfoNameKey=ERROR_ACCOUNT_EXISTS_WITH_DIFFERENT_CREDENTIAL, FIRAuthErrorUserInfoEmailKey=mmmlves@gmail.com, FIRAuthErrorUserInfoUpdatedCredentialKey=<FIROAuthCredential: 0x28287cdc0>, NSLocalizedDescription=An account already exists with the same email address but different sign-in credentials. Sign in using a provider associated with this email address.}

This occurs because I already used this email registering with Goggle/Firebase (what can happen with the user also...)
But I don't receive this event in B4X code (this is only an event showed in log). Then,it isn't possible to know that the authentication failed and the progressdialog raised remains on the screen, almost "locking" the app to the user.

Question: how can I get the event Error Domain=FIRAuthErrorDomain Code=17012 in the B4X code? This didn't trigger the Auth_SignError event...

Thanks for all!!!
 

Erel

Administrator
Staff member
Licensed User
 
Upvote 0

Marcos Alves

Well-Known Member
Licensed User
Hello @Erel .
I don't know if it's the right place to post, but I think that I have a similar problem with Apple Authentication. When the process is cancelled, the internal error code doesn't trigger an event in B4i. See:

error: Error Domain=com.apple.AuthenticationServices.AuthorizationError Code=1001 "(null)" <- this event isn't tracked.

Is this the same situation (library must to be updated to to externalize the event?)

Thanks! (sorry if I posted in the wrong place...)
 
Upvote 0
Top