Usually, Xcode shows a warning when using a strong reference in a block (retain cycle). However, I don't understand why it doesn't show it with this AFNetworking
example.
UIImageView *imageView;
AFHTTPRequestOperation *operation = [apiQueryManager HTTPRequestOperationWithRequest:request success:^(AFHTTPRequestOperation *operation, NSData *responseObject) {
UIImage *image = [UIImage imageWithData:responseObject];
imageView.image =image; // <--- using strong ref to imageView ?
} failure:^(AFHTTPRequestOperation *operation, NSError *error) {
NSLog(@"ERROR: %@", error);
}];
[apiQueryManager enqueueHTTPRequestOperation:operation];
Is there a retain cycle here?