-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Closed
Labels
Description
Incorrect date formats like YYYY-MM/DD and YYYY/MM-DD which contains both hyphen - and forward slash / are being wrongly validated as true.
validator.isDate("2020-10/12"); // returns true
validator.isDate("2020/10-12"); // returns true
Expected Behavior
I think in such cases, isDate() function should return false
Additional context
Validator.js version:^13.1.1
Node.js version:v12.16.1
OS platform: [windows]
LeeviHalme and dcjha