-
Notifications
You must be signed in to change notification settings - Fork 2
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
Use symfony/validator
for as much validation logic as we can throw at it.
#193
Comments
This was referenced Sep 24, 2024
GuySartorelli
assigned emteknetnz and GuySartorelli and unassigned GuySartorelli and emteknetnz
Sep 25, 2024
This was referenced Sep 25, 2024
Closed
Closed
1 task
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In silverstripe/silverstripe-framework#11123 we added a lightweight wrapper around
symfony/validator
, which has a ton of validation constraints we can use all over the place if we want to.Some obvious quick wins:
EmailField
)egulias/email-validator
validation for everything email related)Because this would represent a change in logic, it could break some things so it needs to either be opt-in where it's applied or just be done in a major release.
Acceptance criteria
[ ] Raise new cards for anything that is harderno needValidation applied:
File and image validation would require changing too much code surrounding the validation itself, and locale stuff didn't seem worthwhile.
Most other validation was for things like "not blank" which is trivial to do without relying on symfony (or in the case of
RequiredFields
our setup is currently too idiosyncratic to rely on something that simple)CMS 5 PRs
CMS 6 PRs
The text was updated successfully, but these errors were encountered: