Reputation: 1871
I am having a bit of trouble deleting objects from core data where i am using muti threaded multiple nsmanaged objects context Architecture(http://www.cocoanetics.com/2012/07/multi-context-coredata/).
Should I be deleting the objects by creating a child context or should i delete it from a read context that was created.
Thanks for your help guys.
Upvotes: 0
Views: 166
Reputation: 1243
The link you provided describes 2 different approaches for dealing with multiple contexts.
If you use the first (classic) approach, then i guess that your contexts dont synchronize correctly at some point.
If you use the parent/child pattern (which can make things easier) and you delete an object in a child context, then you need to save the child in order to get the change being pushed to its parent. After that, you need to save the parent as well, if you want to persist the deletion.
Upvotes: 1