ios - PHFetchOptions mediaSubtype predicate -


following predicate should fetch screenshots only, work fine.

options.predicate = [nspredicate predicatewithformat:@"(mediasubtype & %d) != 0", phassetmediasubtypephotoscreenshot]; 

however if try exclude screenshots using follwing predicate, of images excluded

options.predicate = [nspredicate predicatewithformat:@"(mediasubtype & %d) = 0", phassetmediasubtypephotoscreenshot];     

all im trying exlude screeshots asset fetch.

is known bug or missing ?

i made quick check , seems work me:

 phfetchoptions *options = [[phfetchoptions alloc] init];  options.predicate = [nspredicate predicatewithformat:@"(mediasubtype & %d) == 0", phassetmediasubtypephotoscreenshot]; 

note double equal in predicate comparison instead of single one.


Comments

Popular posts from this blog

routing - AngularJS State management ->load multiple states in one page -

python - GRASS parser() error -

post - imageshack API cURL -