*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'FBSDKGraphRequestConnection: [FBSDKSettings appID] must be specified for batch requests'
尝试运行2个批处理请求时出现此错误。下面的代码显示了我所做的。我该如何解决这个问题?
let requestForOSP =
FBSDKGraphRequest(graphPath: FacebookParameters.OSP,
parameters: [ nil ],
httpMethod: "GET")
let requestForMSA =
FBSDKGraphRequest(graphPath: FacebookParameters.MSA,
parameters: [ nil ],
httpMethod: "GET")
let connection = FBSDKGraphRequestConnection()
connection.add(requestForOSP, completionHandler: { (connection, result, error) in
// DO Stuff
}
connection.add(requestForMSA, completionHandler: { (connection, result, error) in
// DO Other Stuff
}
答案 0 :(得分:0)
我解决了。
我必须在这里创建一个Facebook应用:https://developers.facebook.com/apps/,
选择iOS idk,
获取应用编号
将其放入Xcode的plist文件