validating
validating copied to clipboard
saveOrReturn() raises an exception!
I've just noticed that saveOrReturn() raises an exception if $throwValidationExceptions is set true. The documentation suggests that the whole purpose of this function is to avoid throwing an exception, even if the afore-mentioned variable is set. Also I extracted this comment from the code:
/** saveOrReturn()
* Perform a one-off save that will return a boolean on
* validation error instead of raising an exception.
*/