Skip to content

Instantly share code, notes, and snippets.

@quellish
Created August 9, 2014 20:07

Revisions

  1. quellish created this gist Aug 9, 2014.
    8 changes: 8 additions & 0 deletions fetchThingsWithCompletion.m
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,8 @@
    - (void) fetchThingsWithCompletion:(void (^)(NSArray *, NSError *))completion{
    [context performBlock:^{
    result = [context executeFetch:...
    if (completion != nil){
    completion(result, error);
    }
    }];
    }