coldbox-modules / quick

A ColdBox ORM Engine
https://quick.ortusbooks.com
MIT License
23 stars 19 forks source link

Allow Non-Loaded Entities to Return Null Values for Relationships #178

Closed homestar9 closed 2 years ago

homestar9 commented 2 years ago

This change should (hopefully) be pretty straightforward. In order to be able to retrieve null values back for relationships on a non-loaded (new) entity, all of the guardAgainstNotLoaded() checks were removed. I also applied the same fix to isNullValue() as you made in Quick version 5

The rest of the guardAgainstNotLoaded() checks are still in place so you shouldn't be able to create new relationships on a non-loaded entity.

bdw429s commented 2 years ago

This pull request has been mentioned on Ortus Solutions Community. There might be relevant details there:

https://community.ortussolutions.com/t/quick-4-2-4-this-instance-is-not-loaded-so-it-cannot-access-the-relationship/9216/1