From 72231c392648cefaf7145e7ca6f90ec35fcc0338 Mon Sep 17 00:00:00 2001 From: Roland Gruber Date: Mon, 10 Jun 2024 07:42:44 +0200 Subject: [PATCH] refactoring --- rector.php | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/rector.php b/rector.php index 44602e993..11c077c8f 100644 --- a/rector.php +++ b/rector.php @@ -3,23 +3,24 @@ use Rector\Config\RectorConfig; use Rector\Set\ValueObject\LevelSetList; use Rector\Set\ValueObject\SetList; +use Rector\Php81\Rector\FuncCall\NullToStrictStringFuncCallArgRector; -return static function (RectorConfig $rectorConfig): void { - $rectorConfig->paths([ +return RectorConfig::configure() + ->withPaths([ __DIR__ . '/lam/help', - __DIR__ . '/lam/lib', + __DIR__ . '/lam/lib', __DIR__ . '/lam/templates', __DIR__ . '/lam/tests', - ]); - - //$rectorConfig->fileExtensions(['php', 'inc']); - - $rectorConfig->skip([ - __DIR__ . '/lam/lib/3rdParty', - ]); - - $rectorConfig->sets([ - SetList::DEAD_CODE, - LevelSetList::UP_TO_PHP_80 - ]); -}; + ]) + ->withSets([ + SetList::DEAD_CODE, + LevelSetList::UP_TO_PHP_81 + ]) + ->withSkip([ + __DIR__ . '/lam/lib/3rdParty', + NullToStrictStringFuncCallArgRector::class + ]) + ->withFileExtensions([ + 'php', +// 'inc' + ]);