fix: validate entire array and not single elements #1280
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
To be merged after #1279
Closes #1230
Closes #1243
Related #755 (comment)
Maybe it is not the best time for doing this since we just released v7, but I changed my mind about forcing the entire array to comply with the validator.
We provide wildcards which are a great way to validate individual array items.
This PR is born because there are a lot of cases where validating individual items if not requested by the user leads to unexpected results.
Otherwise we can: add a param to body(''), check('')... to explicitly enable/disable array, or keep the current approach.
@gustavohenke wdyt?
To-do list