Not redirect, Facebook.logInWithReadPermissionsAsync

Facebook.logInWithReadPermissionsAsync, doesn’t come back to our app after flying to Facebook app.
This may or may not occur.

Even after logging in on the Facebook app, it behaves like staying in the Facebook app.
The only way to get back to our app is to cancel, and of course the login process will fail.

For now it only occurs on iOS standalone.
It’s pretty strange because it’s quite strange behavior and it hurts user acquisition opportunities.
This is fatal for our app.

"expo": "^35.0.0",
"expo-facebook": "~7.0.0",
"react-native": "https://github.com/expo/react-native/archive/sdk-35.0.0.tar.gz",
import * as firebase from 'firebase';
import * as Facebook from 'expo-facebook';

const signinFacebook = async () => {
  try {
    const {
      type,
      token,
    } = await Facebook.logInWithReadPermissionsAsync(
      ENV.FACEBOOK_APP_ID,
      {
        permissions: ['public_profile', 'email'],
      },
    );

    if (type === 'success') {
      const credential = firebase.auth.FacebookAuthProvider.credential(token);
      return firebase.auth().signInWithCredential(credential).catch((error) => {
        throw error;
      });
    }
  } catch (error) {
    // ERROR
  }
};

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.