Closed pgawlowski closed 7 years ago
Hi,
I don't follow, could you post a pic of your Core Data model?
Thanks! So, the problem here is that after inserting a few cart entries to a cart, doing:
let result = cart.hyp_dictionary(using: .snakeCase, andRelationshipType: .array)
Doesn't print any of the cart entries, right?
Nope. Cart entries are ok. In Core Data Editor I can see proper cartEntries as well as product in every cartEntry - I'm sure that relation exists.
However
let result = cart.hyp_dictionary(using: .snakeCase, andRelationshipType: .array)
doesn't print any products in cart entry unless I uncheck optional for product reference in CartEntry entity.
Right now I'm trying to reset whole DB and check it once again.
I see, that's very strange.
After reset it's working perfect. I will leave this issue open and try to reproduce this problem in another 24h :) Else I'll just close this issue.
Awesome. Gonna put my timer for 24 hours :P
Let's assume core data entity structure like this:
There is CartEntry with product in my Cart - coreData seems to be ok. I'm fetching Cart and as a result I've got:
However when I changed
Everything seems to be fine - fetch result got also products.