2
0

Resolve main thread access issues.

This commit is contained in:
Maarten Billemont
2020-03-25 12:16:19 -04:00
parent 07250d50fd
commit a640b798b5
3 changed files with 23 additions and 45 deletions

View File

@@ -76,10 +76,7 @@
NSDictionary *keyQuery = [self createKeyQueryforUser:user origin:&keyOrigin];
id<MPAlgorithm> keyAlgorithm = user.algorithm;
MPKey *key = [[MPKey alloc] initForFullName:user.name withKeyResolver:^NSData *(id<MPAlgorithm> algorithm) {
return ![algorithm isEqual:keyAlgorithm]? nil:
PearlMainQueueAwait( (id)^{
return [PearlKeyChain dataOfItemForQuery:keyQuery];
} );
return ![algorithm isEqual:keyAlgorithm]? nil: [PearlKeyChain dataOfItemForQuery:keyQuery];
} keyOrigin:keyOrigin];
if ([key keyIDForAlgorithm:user.algorithm])