LearnBoost/mongoose — pull request #1527 by thanpolas (2013-06-12 11:30:55+00:00)
Title: refactor validator error constructor

A refactor of the `ValidatorError` constructor and the `toString()` method so it can be overwritten and achieve a custom error message for the `required` built-in validator.

An interim solution until #747 ships, but a good practice nonetheless. Not sure about the docblock, how would you declare an optional argument? I use `=` coming from the GClosure camp.