React Native Firebase – signInWithPhoneNumber not returning confirmationResult

I'm using react-native-firebase for phone auth from firebase.

I'm following the documentation from and I'm not getting anything from the promise

 // Handle the button press
  async function signInWithPhoneNumber(phoneNumber) {
    const confirmation = await auth().signInWithPhoneNumber(phoneNumber);

I tried expanding it to the below, but still the breakpoint is not being hit in then or catch

async function signInWithPhoneNumber() {
      await auth()
        .then(confirmationResult => {
          // Unreachable point / not able to get a confirmationResult after resolving the promise. 
          console.log('confirmation result');
          console.log(`confirmation= ${confirmationResult}`);
          alert('confirmation result');
        .catch(error => {
          // Error; SMS not sent
          // ...
          console.log(`sms not sent= ${error}`);
          alert('confirmation ERR');

All firebase console setup/gradle is fine, I'm getting an sms from firebase with the security code. Since the resolver object is not received, unable to verify the code from client end.

Any help is appreciated.

Read more here:

Content Attribution

This content was originally published by nullUser at Recent Questions - Stack Overflow, and is syndicated here via their RSS feed. You can read the original post over there.

%d bloggers like this: