support the array of error messages; fix a bug if validator is not passed