I have this method:
+ (MHTwitterParser*)createParser:(NSString*)format {
if ([format compare:@\"json\"] == NSOrderedSame) {
return [[MHJsonTwitt
The warning is there simply because not every path through the code ends with a return statement which the compiler recognizes as potentially problematic. That said, you probably shouldn't be throwing an exception here and should instead be generating an NSError
and returning nil
. The differences between exceptions and errors in objective-c are explained here and here.