In order so that model can process validation, Every validation function must return this type.
valid - if true all errors for property will be cleared
valid - if false - if errors are array - will replace all errors for property with array. if single string, will add it, if
there is no error with this message, else will ignore.
errors - either array of error messages - if valid false will replace all errors for property, if single and false will add error if not there.
In order so that model can process validation, Every validation function must return this type.
valid - if true all errors for property will be cleared valid - if false - if errors are array - will replace all errors for property with array. if single string, will add it, if there is no error with this message, else will ignore.
errors - either array of error messages - if valid false will replace all errors for property, if single and false will add error if not there.