Skip to content

Commit 8d33cb4

Browse files
committed
Improve rector configuration
1 parent 93f463f commit 8d33cb4

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

files/rector.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
use Rector\Php81\Rector\ClassMethod\NewInInitializerRector;
99
use Rector\Php81\Rector\FuncCall\NullToStrictStringFuncCallArgRector;
1010
use Rector\Php82\Rector\Param\AddSensitiveParameterAttributeRector;
11+
use Rector\Php83\Rector\ClassMethod\AddOverrideAttributeToOverriddenMethodsRector;
1112

1213
return RectorConfig::configure()
1314
->withPaths([
@@ -26,4 +27,5 @@
2627
NullToStrictStringFuncCallArgRector::class,
2728
ClassPropertyAssignToConstructorPromotionRector::class,
2829
NewInInitializerRector::class,
30+
AddOverrideAttributeToOverriddenMethodsRector::class,
2931
]);

src/Change/PrepareRectorConfiguration.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public function decide(Context $context): callable|array|null
2222
$original = $context->tryReadFile(self::FILE);
2323

2424
/** @var string $new */
25-
$new = $original ?? file_get_contents(dirname(self::FILE, 2) . '/files/' . self::FILE);
25+
$new = $original ?? file_get_contents(dirname(__DIR__, 2) . '/files/' . self::FILE);
2626

2727
$phpSet = $this->getPhpSet($context);
2828
if ($phpSet === null) {

0 commit comments

Comments
 (0)