Federico Ciardi
Federico Ciardi
I have already proposed this one a year ago or so and it got rejected, hope something has changed!
@stevensacks I was also adding aliases https://github.com/validatorjs/validator.js/pull/1522/files#diff-bfe9874d239014961b1ae4e89875a6155667db834a410aaaa2ebe3cf89820556R210-R230
Deprecating code is exactly that, it means keeping it available in the codebase to maintain backward compatibiliy but suggesting users to use another function/variable. Deprecating a function doesn't necessarily mean...
Is it a sanitizer? It doesn't return a new value. https://github.com/validatorjs/validator.js/blob/master/src/lib/isBoolean.js
Ho @davidnbooth, does the following work for you? ```js const validator = require('validator').default ```
Hey @vnvyvu, does it work if you pass a string instead of a regexp? ```js body('pass').matches('(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[\W]).{8,}', 'gm') ```
It has to be fixed for Regex objects however.
Yeah, that happened to me too some times ago but never had a change to investigate it properly. I can't reproduce it in express-validator unit testing. It will be fixed...
I'm not sure, but I assume it is.
Found this comment: https://github.com/express-validator/express-validator/issues/1127#issuecomment-1026730522 Apparently `pattern.test(str)` is unreliable when preserving the same instance of a regex object, instead `str.match(pattern)` is. @tux-tn would a PR to change that method in this...