how to set delegate to nil?
my table view controller calls below in viewDidLoad
myFBRequest= [facebook requestWithGraphPath:[NSString stringWithFormat:@"%@/feed", myId] andDelegate:self];
and in dealloc,
if (myFBRequest) myFBRequest=nil;
I do that because if user clicks on back button, I wanna ignore the response that came or coming back.
however, I get the below error
* -[FB开发者_JS百科Request setDelegate:]: message sent to deallocated instance 0x823e190
Why is that? I thought I have to set delegate to nil if I dont' want the response anymore?
I'm so confused.
Any help would be appreciated
Thanks, Bec
yes you can pass in andDelegate:nil
if you don't want to response delegates.
精彩评论