Skip to content

Commit 556edd4

Browse files
committed
Merge remote-tracking branch 'upstream/develop' into simplify-install-instructions
2 parents e43bd79 + e0f31fa commit 556edd4

7 files changed

+31
-35
lines changed

Magento2/Rector/Src/AddArrayAccessInterfaceReturnTypes.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
use PhpParser\Node;
1111
use PhpParser\Node\Stmt\Class_;
12-
use Rector\Core\Rector\AbstractRector;
12+
use Rector\Rector\AbstractRector;
1313
use Symplify\RuleDocGenerator\ValueObject\CodeSample\CodeSample;
1414
use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
1515

Magento2/Rector/Src/ReplaceMbStrposNullLimit.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
use PhpParser\Node;
1111
use PhpParser\Node\Expr\FuncCall;
1212
use PhpParser\Node\Scalar\LNumber;
13-
use Rector\Core\Rector\AbstractRector;
13+
use Rector\Rector\AbstractRector;
1414
use Symplify\RuleDocGenerator\ValueObject\CodeSample\CodeSample;
1515
use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
1616

Magento2/Rector/Src/ReplaceNewDateTimeNull.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
use PhpParser\Node;
1111
use PhpParser\Node\Expr\New_;
1212
use PhpParser\Node\Scalar\String_;
13-
use Rector\Core\Rector\AbstractRector;
13+
use Rector\Rector\AbstractRector;
1414
use Symplify\RuleDocGenerator\ValueObject\CodeSample\CodeSample;
1515
use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
1616

Magento2/Rector/Src/ReplacePregSplitNullLimit.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
use PhpParser\Node;
1111
use PhpParser\Node\Expr\ConstFetch;
1212
use PhpParser\Node\Expr\FuncCall;
13-
use Rector\Core\Rector\AbstractRector;
13+
use Rector\Rector\AbstractRector;
1414
use Symplify\RuleDocGenerator\ValueObject\CodeSample\CodeSample;
1515
use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
1616

composer.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66
"AFL-3.0"
77
],
88
"type": "phpcodesniffer-standard",
9-
"version": "33",
9+
"version": "34",
1010
"require": {
1111
"php": "~8.1.0 || ~8.2.0 || ~8.3.0",
1212
"dealerdirect/phpcodesniffer-composer-installer": "^0.7.2 || ^1.0",
1313
"webonyx/graphql-php": "^15.0",
1414
"ext-simplexml": "*",
1515
"ext-dom": "*",
1616
"squizlabs/php_codesniffer": "^3.6.1",
17-
"rector/rector": "^0.17.12",
17+
"rector/rector": "^1.2.4",
1818
"phpcsstandards/phpcsutils": "^1.0.5",
1919
"magento/php-compatibility-fork": "^0.1"
2020
},

composer.lock

+16-17
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rector.php

+9-12
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use Magento2\Rector\Src\ReplaceMbStrposNullLimit;
66
use Magento2\Rector\Src\ReplaceNewDateTimeNull;
77
use Rector\Config\RectorConfig;
8-
use Rector\Core\ValueObject\PhpVersion;
8+
use Rector\ValueObject\PhpVersion;
99
use Rector\Php80\Rector\Class_\StringableForToStringRector;
1010
use Rector\Php80\Rector\ClassMethod\FinalPrivateToPrivateVisibilityRector;
1111
use Rector\CodeQuality\Rector\ClassMethod\OptionalParametersAfterRequiredRector;
@@ -17,16 +17,13 @@
1717
$rectorConfig->phpVersion(PhpVersion::PHP_80);
1818
$rectorConfig->phpVersion(PhpVersion::PHP_81);
1919

20-
// get services (needed for register a single rule)
21-
$services = $rectorConfig->services();
22-
2320
// register a single rule
24-
$services->set(FinalPrivateToPrivateVisibilityRector::class);
25-
$services->set(OptionalParametersAfterRequiredRector::class);
26-
$services->set(SetStateToStaticRector::class);
27-
$services->set(StringableForToStringRector::class);
28-
$services->set(Php81ResourceReturnToObjectRector::class);
29-
$services->set(ReplacePregSplitNullLimit::class);
30-
$services->set(ReplaceMbStrposNullLimit::class);
31-
$services->set(ReplaceNewDateTimeNull::class);
21+
$rectorConfig->singleton(FinalPrivateToPrivateVisibilityRector::class);
22+
$rectorConfig->singleton(OptionalParametersAfterRequiredRector::class);
23+
$rectorConfig->singleton(SetStateToStaticRector::class);
24+
$rectorConfig->singleton(StringableForToStringRector::class);
25+
$rectorConfig->singleton(Php81ResourceReturnToObjectRector::class);
26+
$rectorConfig->singleton(ReplacePregSplitNullLimit::class);
27+
$rectorConfig->singleton(ReplaceMbStrposNullLimit::class);
28+
$rectorConfig->singleton(ReplaceNewDateTimeNull::class);
3229
};

0 commit comments

Comments
 (0)