Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PhoneProvider consistency between IOS and Android #155

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

PhoneProvider consistency between IOS and Android #155

wants to merge 1 commit into from

Conversation

jdordoigne
Copy link

Today in IOS the verification code is not sent in the signIn callback. This means that the user is not authenticated on javascript and allow the user to link to an existing account or sign in (like example).
In android we can have the validation code, and it will directly signIn the user and cancel the possibility to link phone number with an existing account.

To keep consistency between ios and android we should send the same information / do the same thing.

As this is a breaking changes it could be added in v3 if you are ok with this.

Today in IOS the verification code is not sent in the signIn callback. This means that the user is not authenticated on javascript and allow the user to link to an existing account or sign in (like example).
In android we can have the validation code, and it will directly signIn the user and cancel the possibility to link phone number with an existing account.

To keep consistency between ios and android we should send the same information / do the same thing.

As this is a breaking changes it could be added in v3 if you are ok with this.
@baumblatt
Copy link
Owner

baumblatt commented Mar 25, 2021

Hi, @jdordoigne ,

In my opinion the feature of SignIn on Android without the user enter de verification code is wonderful, this was not implemented on iOS, because the Firebase SDK can't read the verification code automatic.

But I understand you requirement and we can implement this behavior using a flag in configuration or parameter in the call.

I will take a look on this, but I think that the best option is handle everything on web tier without changes on java code.

Finally, please, in case you try to review your implementation, please use the next branch for merges.

Best regards.

@jdordoigne
Copy link
Author

Hi and thanks for the feedback !
I was focus on the native side and not on the client. I dig up the code and indeed we could use a flag on js side that won’t break existing behavior.

You can still automatically login the user as cfaSignInPhoneOnCodeReceived is called for this purpose.

Noted for the branch my bad !

@nelson6e65
Copy link

nelson6e65 commented Apr 15, 2021

There is a way to skip the "auto-detection" from javascript facades?
I call cfaSignInPhone() but never completes on Android, nor fails. I want to be able to use testing phone numbers too.

There is a way to "We sent the sms" instead of "We are waiting to detect phone number" on Android? Thanks in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants