The first example in the README has a property with a field named `default` but the code doesn't seem to implement it. Maybe add after [revalidator.js:253](https://github.com/flatiron/revalidator/blob/master/lib/revalidator.js#L253) something like: ``` } else if (schema.default !== undefined) { object[property] = schema.default; return; } ``` And document that it sets the `default` value on the object's property if it doesn't exist and isn't required?
Activity
Use default value if specified. Fixes flatiron#85.
Use default value if specified. Fixes flatiron#85.
Fortur commentedon Aug 31, 2020
Please, implement this feature. In my case, need to replase empty and null values to defalt value