diff --git a/rules/Configs/Rector/Closure/ServiceSettersToSettersAutodiscoveryRector.php b/rules/Configs/Rector/Closure/ServiceSettersToSettersAutodiscoveryRector.php index 92af8194d..14aec1010 100644 --- a/rules/Configs/Rector/Closure/ServiceSettersToSettersAutodiscoveryRector.php +++ b/rules/Configs/Rector/Closure/ServiceSettersToSettersAutodiscoveryRector.php @@ -218,7 +218,7 @@ private function createAbsolutePathConcat(string $classFilePath): Concat { $relativeDirectoryPath = $this->filesystem->makePathRelative( dirname($classFilePath), - dirname($this->getFile()->getFilePath()) + dirname((string) $this->getFile()->getFilePath()) ); $distConstFetch = new ConstFetch(new Name('__DIR__')); diff --git a/rules/Symfony30/Rector/MethodCall/StringFormTypeToClassRector.php b/rules/Symfony30/Rector/MethodCall/StringFormTypeToClassRector.php index bc7f0f3fc..98987db42 100644 --- a/rules/Symfony30/Rector/MethodCall/StringFormTypeToClassRector.php +++ b/rules/Symfony30/Rector/MethodCall/StringFormTypeToClassRector.php @@ -73,7 +73,6 @@ public function refactor(Node $node): ?Node return null; } - /** @var String_ $stringNode */ $stringNode = $firstArg->value; // not a form type string diff --git a/rules/Symfony43/Rector/MethodCall/ConvertRenderTemplateShortNotationToBundleSyntaxRector.php b/rules/Symfony43/Rector/MethodCall/ConvertRenderTemplateShortNotationToBundleSyntaxRector.php index 972db6e03..e64b6145e 100644 --- a/rules/Symfony43/Rector/MethodCall/ConvertRenderTemplateShortNotationToBundleSyntaxRector.php +++ b/rules/Symfony43/Rector/MethodCall/ConvertRenderTemplateShortNotationToBundleSyntaxRector.php @@ -112,7 +112,7 @@ public function refactor(Node $node): ?Node } if (! isset($matches[0])) { - return null;t + return null; } $newValue = '@' . diff --git a/rules/Symfony44/Rector/ClassMethod/ConsoleExecuteReturnIntRector.php b/rules/Symfony44/Rector/ClassMethod/ConsoleExecuteReturnIntRector.php index 7878bfa67..e574117ee 100644 --- a/rules/Symfony44/Rector/ClassMethod/ConsoleExecuteReturnIntRector.php +++ b/rules/Symfony44/Rector/ClassMethod/ConsoleExecuteReturnIntRector.php @@ -163,13 +163,11 @@ private function isReturnIntegerType(?Expr $expr): bool private function isIntegerTernaryIfElse(Ternary $ternary): bool { - /** @var Expr|null $if */ $if = $ternary->if; if (! $if instanceof Expr) { $if = $ternary->cond; } - /** @var Expr $else */ $else = $ternary->else; $ifType = $this->getType($if); $elseType = $this->getType($else);