Using FB SDK 3.6, I am attempting to capture FB User IDs and save to Parse datastore in the cloud to build a custom audience to market to. My call is as follows:
[FBRequestConnection startForCustomAudienceThirdPartyID:nil
completionHandler:^(FBRequestConnection *connection, id result, NSError *error) {
NSString *uid = error ? nil : [result objectForKey:@"custom_audience_third_party_id"];
if ([uid length] > 0) {
PFObject *newInstall = [PFObject objectWithClassName:@"NewInstalls"];
[newInstall setObject:uid forKey:@"FacebookUID"];
[newInstall saveEventually]; //saves whenever user is online
}
}];
It works beautifully on the simulator (v6.1), but when I run on the device (iPhone 5, v6.1.2) it makes the call, but the completion handler never runs. Any suggestions?