Open imhoff opened 11 years ago
Hi, I am not sure what to do about this one because it sounds like a good thing rather than a bad thing.
Any idea what you would expect to happen? We could possibly catch the exception and raise a more specific one.
I was just a little surprised that the Exception was thrown. Given the name and the behavior of the ActiveRecords, I assumed that it would do just nothing if there is nothing to be saved. As the class already tracks which portions have changed (dirty flag) it seems strange that there is an error at all. But its just my point of view.
Cheers, you are not wrong, we should probably just make it fail silently in this scenario, I will look into it.
When creating an
ActiveRecord
and calling thesave()
method without touching its values will throw anIllegalArgumentsException: Empty Values
. It is not checked whether the constructedContentValues
Object contains any values.