I have a question regarding the predicate I am using in the following code
NSMutableArray *records = (__bridge NSMutableArray *)ABAddressBookCopyArrayOfAllPeople( addressBook );
NSPredicate *predicate = [NSPredicate predicateWithFormat:@"record.phoneNumber contains %@",@"123"];
@try {
[records filterUsingPredicate:predicate];
}
@catch (NSException *exception) {
NSLog(@"%@",exception);
}
@finally {
//
}
The exception I get is:
[<__NSCFType 0x6e2c5e0> valueForUndefinedKey:]: this class is not key value coding-compliant for the key record.
I've been trying to find a guide on predicates for address book with no luck though. Any suggestions?