我正在使用
Xcode 7.0,在iOS 9.0.2上测试并使用Facebook SDK 4.7.0. Code = 308“(null)”iOS 9中出现问题.我在项目中使用了objective-c代码.怎么解决这个?
下面附上我的代码.
下面附上我的代码.
FBSDKLoginManager *login = [[FBSDKLoginManager alloc] init]; [login logInWithReadPermissions:@[@"public_profile",@"email",@"user_friends"] fromViewController:self handler:^(FBSDKLoginManagerLoginResult *result,NSError *error){ if ([FBSDKAccessToken currentAccessToken]) { startWithCompletionHandler:^(FBSDKGraphRequestConnection *connection,id result,NSError *error) { if (!error) { } }]; } }];
解决方法
iOS9.2.1
这解决了我的308问题
打开’源代码’,plist文件,搜索LSApplicationQueriesSchemes,然后根据需要添加/修改.
<key>LSApplicationQueriesSchemes</key> <array> <string>fbauth2</string> <string>fbapi</string> <string>fb-messenger-api</string> <string>fbshareextension</string> </array>