“Missing __block type specifier” compilation error after refactoring code but ok before refactor
I have some code that downloads an image and assigns it within a block. The code currently works however I want to refactor it into a separate method, however after the refactoring I get a compilation error. This is the original code which compiles and runs with the downloaded image being assigned successfully: - (void) someMethod { … MyObject* object = [[MyObject alloc] init]; [self.objects addObject: object]; NSString* graphRequest = [NSString stringWithFormat:@"%@%@%@", @"https://graph.facebook.com/", fbid, @"/picture?type=square"]; FBRequest *fbRequest = [FBRequest requestForGraphPath: