optimizations

This commit is contained in:
John Estropia
2019-11-29 20:09:43 +09:00
parent 4ee1b04523
commit b12dba4d15
7 changed files with 92 additions and 25 deletions

View File

@@ -98,7 +98,7 @@ extension DynamicObject where Self: ObjectRepresentation {
public func asPublisher(in dataStack: DataStack) -> ObjectPublisher<Self> {
let context = dataStack.unsafeContext()
return ObjectPublisher<Self>(objectID: self.cs_id(), context: context)
return context.objectPublisher(objectID: self.cs_id())
}
public func asReadOnly(in dataStack: DataStack) -> Self? {