Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[OptionsResolver] performing validation before filters #4500

Copy link
Copy link
@sstok

Description

@sstok
Issue body actions

Currently the OptionsResolver performs filtering before validating.
Which is kind of weird.

When I set an value that can only be an string or null the filtering is performed before the actual type validating.
So I still need to check in my filtering function whether the input value is accepted and throw an exception (with not to much information as that is not available), second when my filtering function returns something else like an object I get an error because type does not match.

Should it be better to perform type validation before performing filtering or add an different method for adding validations that will be performed bore filtering?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.