-
-
Notifications
You must be signed in to change notification settings - Fork 627
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a method to manually add errors #26
Comments
I found a much more elegant solution. expressValidator.Validator.prototype.fail = function(str) {
this.error(this.msg);
return this;
}; Maybe this could be added as an example. Because the documentation lacks information about how to add a validator. |
if that's the case, maybe keep this open so that the documentation can be added to fix the problem :p |
I'll just create a PR for the documentation. Give me a sec. Done #27 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I'd like to manually add validation errors for cases were complex validation is needed.
E.g.
I don't want to mess with
req._validationErrors
directly.Does this sound reasonable?
Any chance this will get pulled if I create a PR?
The text was updated successfully, but these errors were encountered: