Open pmalouin opened 7 years ago
When updating to latest version (0.7.0), I can't get "date" validations to run properly. See:
vagrant@spitdev:/opt/app$ node > var checkit = require('checkit'); undefined > var c = new checkit({a:'date'}); undefined > var body = {a:new Date()}; undefined > c.run(body).catch(err => console.log(err)); Promise { <pending> } > { [Error: 1 invalid values] message: '1 invalid values', errors: { a: { [Error: No validation defined for date] message: 'No validation defined for date', errors: [Object], key: 'a' } } }
I presume the problem is caused by commit 3307c84aed50a560260c16ea307300452dae9b20, which did not bring in the isDate method?
isDate
The version 0.7 is broken use 0.6 install with: npm install checkit@0.6
When updating to latest version (0.7.0), I can't get "date" validations to run properly. See:
I presume the problem is caused by commit 3307c84aed50a560260c16ea307300452dae9b20, which did not bring in the
isDate
method?