The following code throws an NSInvalidArgumentException on the call to fetchAssetsWithOptions:
PHFetchOptions *allPhotosOptions = [[PHFetchOptions alloc] init];
allPhotosOptions.sortDescriptors =
@[[NSSortDescriptor sortDescriptorWithKey:@"creationDate" ascending:NO]];
allPhotosOptions.predicate =
[NSPredicate predicateWithFormat:@"pixelHeight >= pixelWidth * 1.95" ];
self.allPhotos = [PHAsset fetchAssetsWithOptions:allPhotosOptions];
The message is
NSInvalidArgumentException ... reason: '*** -constantValue only defined for abstract class.
Define -[NSFunctionExpression constantValue]!'
I tried numerous variations on the predicate format string, but always get this message when I try to use multiplication. What am I doing wrong?