Closed dewos closed 14 years ago
I agree actually.
How should this be handled? Should an exception be thrown? Should save() return a boolean? I'll definitely add this but I want to hear some opinions on how the API should work.
Save just call check(). Validation Class throws the exceptions (if any).
The validation class doesn't throw any exceptions on failure.
if ( ! $data->check())
{
throw new Validate_Exception($data);
}
See title :)