Comments (3)
Isn't it working correctly? I will use some absolute numbers to make the conversation easy to understand.
- Given, today is "12th May, 2023".
- The
rule.before(2, 'years')
says, the date should be before "12th May, 2021". As per this rule:- "11th May, 2021" is correct.
- "11 November, 2020" is correct
- "1st Jan, 1990" is correct
- What you are sending in the request is "12th May, 2022". Which is not before 2 years.
from validator.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
from validator.
Closing since no answer from issue reporter.
from validator.
Related Issues (20)
- `minLength` rule doesn't respect `trim` rule HOT 2
- I want to extend a base validator (reduce duplicity) - AdonisJS v.5 HOT 2
- Cannot find module in production mode HOT 3
- Get return type of validator HOT 2
- Property 'alphaNum' does not exist on type 'Rules'. HOT 1
- Update luxon to v3
- Options for Email is set but not used HOT 1
- Error 500 on validation HOT 2
- Error 500 on validation 2 HOT 2
- Issue in document HOT 1
- Exists validation failed on Id even the Id exists in the postgres HOT 1
- Passing options to the rule not working? HOT 1
- Why it throw an exception when i send empty string HOT 1
- Validate Array as Schema HOT 4
- Create `min` and `max` validators for number type HOT 2
- object().members() accept properties that are not defined HOT 1
- enum or enumSet is not working with i18n JSON HOT 8
- how to manipulate a field from adonis validator? HOT 2
- Forcing request.validate() to run only for body HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from validator.