Closed MRtootisabz closed 1 month ago
Thanks for reporting! However, the code you have given can not throw this exception. Maybe you can share what code line throws the error?
Maybe some helpful pointers:
targetId
or target
, not both.Optimization: for convenience, an object with a ToOne will put the target object as well if the ID of the target object is 0.
Note: I labeled this issue with "more info required" so it will auto-close in a few days if there are no follow-up comments.
thank you for your response, this solved my problem.
Is there an existing issue?
Build info
dart 3.5.3
]Steps to reproduce
Expected behavior
i want to update box with new data. when get data from server i update the model my model has a toOne relation. I update the to one relation model target and targetId. it give this error : <Bad state: ToOne relation field not initialized. Make sure attach(store) is called before using this.>
issue: data not updating in object box
entity class: