Using the IOS SDK for Facebook (3.1) , I find that once I set up my project, I am unable to change the default audience.
For instance, I set up my test project to publish to “Only Me”. It works fine. I am working off of this example, making the change that I start out with audience “Only Me”.
http://developers.facebook.com/docs/howtos/publish-to-feed-ios-sdk/
Then I arrange to call the following:
[FBSession.activeSession
reauthorizeWithPublishPermissions:
[NSArray arrayWithObject:@"publish_actions"]
defaultAudience:FBSessionDefaultAudienceFriends
completionHandler:^(FBSession *session, NSError *error) {
if (!error) {
// If permissions granted, publish the story
NSLog (@"Here goes nothing");
[self publishStory];
}
}];
which should publish the story to DefaultAudienceFriends. However, it continues to publish to Only Me.
Shouldn’t this work? Am I missing something?
Ok, here is the answer I came up with, which addresses my particular need. I change the privacy settings for the app, in Facebook, here:
http://www.facebook.com/settings?tab=applications
And come to think of it, this makes sense. I, as a user of this app (which I happened to create, but that probably isn’t relevant), am specifying the behavior it displays when it posts on my behalf.
So I’m happy, because now I can work on my app, freely test it, without disturbing anybody. And I can change it to post more widely, when I’m ready.