Skip to content

Commit 964ea93

Browse files
authored
FinalPropertyPromotionRector.php
1 parent b053cf7 commit 964ea93

1 file changed

Lines changed: 0 additions & 18 deletions

File tree

rules/Php85/Rector/Class_/FinalPropertyPromotionRector.php

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,8 @@ public function refactor(Node $node): ?Node
7878
}
7979

8080
$hasChanged = false;
81-
8281
$params = $constructClassMethod->getParams();
8382

84-
if ($this->shouldSkipParams($params)) {
85-
return null;
86-
}
87-
8883
foreach ($params as $param) {
8984
if (! $param->isPromoted()) {
9085
continue;
@@ -128,17 +123,4 @@ private function shouldSkip(Class_ $class): bool
128123

129124
return false;
130125
}
131-
132-
/**
133-
* @param Param[] $params
134-
*/
135-
private function shouldSkipParams(array $params): bool
136-
{
137-
foreach ($params as $param) {
138-
if ($this->visibilityManipulator->hasVisibility($param, Visibility::FINAL) && $param->isPromoted()) {
139-
return true;
140-
}
141-
}
142-
return false;
143-
}
144126
}

0 commit comments

Comments
 (0)