Commit 31e50c7
committed
minor #7592 Drop misleading
This PR was merged into the 5.x branch.
Discussion
----------
Drop misleading `@internal` annotation on TextFilterType
``TextFilterType`` carried ```@internal` Don't use this to define a text filter. Use Filter\\TextFilter instead.``, but ``Filter\\TextFilter::new()`` itself does ``->setFormType(TextFilterType::class)``: any custom filter that wants to reuse the text-filter form (e.g. an OR-flavored text filter) must reference ``TextFilterType``. The annotation made phpstan flag every legitimate external reference and steered users toward ``Filter\\TextFilter`` instead, which is not a ``FormTypeInterface`` and crashes the form registry.
Removing the annotation aligns ``TextFilterType`` with the 8 sibling ``*FilterType`` classes (``ArrayFilterType``, ``BooleanFilterType``, ``ChoiceFilterType``, ``ComparisonFilterType``, ``DateTimeFilterType``, ``EntityFilterType``, ``NullFilterType``, ``NumericFilterType``) which carry no such annotation. No behavior change.
Closes #7393
Commits
-------
dd676f9 Drop misleading `@internal` annotation on TextFilterType@internal annotation on TextFilterType (lacatoire)1 file changed
Lines changed: 0 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
15 | | - | |
16 | 14 | | |
17 | 15 | | |
18 | 16 | | |
| |||
0 commit comments