Skip to content

Commit 3f23985

Browse files
authored
Revert "[Php84] Skip has mix between normal property and readonly promoted pr…" (#7505)
This reverts commit 64f20de.
1 parent 64f20de commit 3f23985

File tree

2 files changed

+0
-40
lines changed

2 files changed

+0
-40
lines changed

rules-tests/Php84/Rector/Class_/PropertyHookRector/Fixture/skip_mix_with_existing_readonly_promoted_property.php.inc

Lines changed: 0 additions & 29 deletions
This file was deleted.

rules/Php84/NodeFinder/SetterAndGetterFinder.php

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
use PhpParser\Node\Stmt\Class_;
88
use PhpParser\Node\Stmt\ClassMethod;
99
use Rector\TypeDeclaration\NodeAnalyzer\ClassMethodAndPropertyAnalyzer;
10-
use Rector\ValueObject\MethodName;
1110

1211
final readonly class SetterAndGetterFinder
1312
{
@@ -23,16 +22,6 @@ public function findGetterAndSetterClassMethods(Class_ $class, string $propertyN
2322
{
2423
$classMethods = [];
2524

26-
$constructClassMethod = $class->getMethod(MethodName::CONSTRUCT);
27-
28-
if ($constructClassMethod instanceof ClassMethod) {
29-
foreach ($constructClassMethod->params as $param) {
30-
if ($param->isReadonly()) {
31-
return [];
32-
}
33-
}
34-
}
35-
3625
$getterClassMethod = $this->findGetterClassMethod($class, $propertyName);
3726
if ($getterClassMethod instanceof ClassMethod) {
3827
$classMethods[] = $getterClassMethod;

0 commit comments

Comments
 (0)