FBSDKInternalUtility always returns isFacebookAppInstalled equal to 0
See original GitHub issueThis bug only affects iOS standalone app’s Facebook login because only facebook-ios-sdk
detects is Facebook app installed and changes UI depending on this
https://github.com/facebook/facebook-ios-sdk/blob/master/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManager.m#L364`
Environment
software | version |
---|---|
expo | 26.0.0 |
react-native | https://github.com/expo/react-native/archive/sdk-26.0.0.tar.gz |
exp diagnostics
output

App’s target is iOS Standalone
Steps to Reproduce
On any Expo standalone app on iOS try to login with Facebook with behavior “browser” when you have installed Facebook app. Then remove Facebook app from your device and try to do the same.
You will always see the same UI. This is a bug.
Expected Behavior
Should work in the way like it works in Wolt app
If I set behavior “browser” for Facebook login and Facebook app is installed on the device, on iOS user should see UI with “Log in with the Facebook app” button and be able to login without entering email and password

If I set behavior “browser” for Facebook login and Facebook app is not installed on the device, on iOS user should see UI without “Log in with the Facebook app” button

Actual Behavior
When I set behavior “browser” for Facebook login and Facebook app is installed on the device, on iOS I see UI without “Log in with the Facebook app” button

Reproducible Demo
The only thing you can test is to see how UI looks for different auth urls using browser dev tools

The difference between urls is only in one character
on left
fbapp_pres=1
on right
fbapp_pres=0
I think the problem is in your private FBSDKInternalUtility
It always returns 0 in this line in facebook-ios-sdk
loginParams[@"fbapp_pres"] = @([FBSDKInternalUtility isFacebookAppInstalled]);
I would fix it by myself, but it is not possible as it is in your private module 😃
@terribleben please fix it.
Issue Analytics
- State:
- Created 5 years ago
- Comments:13 (10 by maintainers)
It looks like our app builder code had a regression where it stopped adding the Facebook application scheme to your Expo app’s configuration. I’ve committed a change to fix this which will go out next time we deploy our app builder.
In the meantime, I think a workaround would be to add
[ "fbapi", "fb-messenger-api", "fbauth2'", "fbshareextension" ]
to yourapp.json
underios.infoPlist.LSApplicationQueriesSchemes
, for example…and then re-run
exp build:ios
after making that change.After we deploy the change and close this ticket, the workaround will no longer be needed (because it will be added automatically as long as your app has a
FacebookAppID
).Everything works for us. I am closing this issue. Thanks again @terribleben