diff --git a/Source/Classes/Pull/PullOperation.swift b/Source/Classes/Pull/PullOperation.swift index 56810d0..1bd52bd 100644 --- a/Source/Classes/Pull/PullOperation.swift +++ b/Source/Classes/Pull/PullOperation.swift @@ -35,7 +35,9 @@ public class PullOperation: Operation { let convertOperation = RecordToCoreDataOperation(parentContext: context, record: record) convertOperation.errorBlock = { self.errorBlock?($0) } convertOperation.completionBlock = { - self.objectsWithMissingReferences.append(convertOperation.missingObjectsPerEntities) + context.performAndWait { + self.objectsWithMissingReferences.append(convertOperation.missingObjectsPerEntities) + } } self.queue.addOperation(convertOperation) }