validate() returns an array of errors.