Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Date validator enhancement: before/after/onOrBefore/onOrAfter accept a function that returns a date #281

Merged

Conversation

steveszc
Copy link
Contributor

@steveszc steveszc commented Feb 8, 2021

The Date validator's before/after/onOrBefore/onOrAfter options now
accept a function that returns a date, which is re-evaluated everytime
the validator runs. This allows the date validation logic to
change in between validations, which is useful for situations where
date validation logic is based on date values that may change in between
validations.

Related to #204

The Date validator's before/after/onOrBefore/onOrAfter options now
accept a function that returns a date, which is re-evaluated everytime
the validator runs. This allows the date validation logic to
change in between validations, which is useful for situations where
date validation logic is based on date values that may change in between
validations.
Copy link
Collaborator

@snewcomer snewcomer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wonderful!

@snewcomer snewcomer merged commit 5f0daf7 into adopted-ember-addons:master Feb 8, 2021
@steveszc steveszc deleted the date-validator-functions branch March 31, 2021 04:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants