From 1e3d837b01b587d777ad6cccccd7c81d6794a974 Mon Sep 17 00:00:00 2001 From: TomasVotruba <924196+TomasVotruba@users.noreply.github.com> Date: Sun, 25 May 2025 00:39:21 +0000 Subject: [PATCH] [automated] Apply Coding Standard --- .../FuncCall/DynamicClassConstFetchRector.php | 15 ++++++++------- .../config/configured_rule.php | 4 +++- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/rules/Php83/Rector/FuncCall/DynamicClassConstFetchRector.php b/rules/Php83/Rector/FuncCall/DynamicClassConstFetchRector.php index cb2c6c3b617..d21960dde7b 100644 --- a/rules/Php83/Rector/FuncCall/DynamicClassConstFetchRector.php +++ b/rules/Php83/Rector/FuncCall/DynamicClassConstFetchRector.php @@ -26,18 +26,19 @@ public function getRuleDefinition(): RuleDefinition return new RuleDefinition( 'constant(Example::class . \'::\' . $constName) to dynamic class const fetch Example::{$constName}', [ - new CodeSample( - <<<'CODE_SAMPLE' + new CodeSample( + <<<'CODE_SAMPLE' constant(Example::class . '::' . $constName); CODE_SAMPLE - , - <<<'CODE_SAMPLE' + , + <<<'CODE_SAMPLE' Example::{$constName}; CODE_SAMPLE - , - ), + , + ), - ]); + ] + ); } public function getNodeTypes(): array diff --git a/tests/Issues/ChangeSwitchTernary/config/configured_rule.php b/tests/Issues/ChangeSwitchTernary/config/configured_rule.php index c17e0a448ff..9bfc3eec3ea 100644 --- a/tests/Issues/ChangeSwitchTernary/config/configured_rule.php +++ b/tests/Issues/ChangeSwitchTernary/config/configured_rule.php @@ -8,4 +8,6 @@ use Rector\Tests\Issues\ChangeSwitchTernary\Source\AnotherExpressionRector; return RectorConfig::configure() - ->withRules([ChangeSwitchToMatchRector::class, TernaryFalseExpressionToIfRector::class, AnotherExpressionRector::class]); + ->withRules( + [ChangeSwitchToMatchRector::class, TernaryFalseExpressionToIfRector::class, AnotherExpressionRector::class] + );