Skip to content

Commit 9dcd9a1

Browse files
committed
Fix duplicate registration of RepositoryMethodCallRule
RepositoryMethodCallRule was registered twice: once in the `rules:` section (autowired with checkOrderByFields defaulting to false) and again as a tagged service in `services:` wiring checkOrderByFields to the bleedingEdge feature toggle. Both registrations carry the phpstan.rules.rule tag, so the rule executed twice and reported every magic findBy*/findOneBy* violation as a duplicate. Keep only the `services:` registration, which is the intended one as it wires the checkOrderByFields toggle introduced together with the duplicate. Co-Authored-By: Claude Code
1 parent 5485522 commit 9dcd9a1

1 file changed

Lines changed: 0 additions & 1 deletion

File tree

rules.neon

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ parametersSchema:
2020

2121
rules:
2222
- PHPStan\Rules\Doctrine\ORM\DqlRule
23-
- PHPStan\Rules\Doctrine\ORM\RepositoryMethodCallRule
2423
- PHPStan\Rules\Doctrine\ORM\EntityConstructorNotFinalRule
2524
- PHPStan\Rules\Doctrine\ORM\EntityMappingExceptionRule
2625
- PHPStan\Rules\Doctrine\ORM\EntityNotFinalRule

0 commit comments

Comments
 (0)