From f0969dcb207e305f26dcb0da09bec4f1fca67881 Mon Sep 17 00:00:00 2001 From: Tomas Votruba Date: Fri, 31 Jul 2026 19:00:52 +0200 Subject: [PATCH] [depre] Remove StringExtensionToConfigBuilderRector deprecated since 2025-10 The rule has been throwing on refactor() for 9 months. It is not part of any set and has no tests left. --- .../StringExtensionToConfigBuilderRector.php | 72 ------------------- 1 file changed, 72 deletions(-) delete mode 100644 rules/CodeQuality/Rector/Closure/StringExtensionToConfigBuilderRector.php diff --git a/rules/CodeQuality/Rector/Closure/StringExtensionToConfigBuilderRector.php b/rules/CodeQuality/Rector/Closure/StringExtensionToConfigBuilderRector.php deleted file mode 100644 index 6ad5e5f9b..000000000 --- a/rules/CodeQuality/Rector/Closure/StringExtensionToConfigBuilderRector.php +++ /dev/null @@ -1,72 +0,0 @@ -extension('security', [ - 'firewalls' => [ - 'dev' => [ - 'pattern' => '^/(_(profiler|wdt)|css|images|js)/', - 'security' => false, - ], - ], - ]); -}; -CODE_SAMPLE - - , - <<<'CODE_SAMPLE' -use Symfony\Config\SecurityConfig; - -return static function (SecurityConfig $securityConfig): void { - $securityConfig->firewall('dev') - ->pattern('^/(_(profiler|wdt)|css|images|js)/') - ->security(false); -}; -CODE_SAMPLE - ), - ]); - } - - /** - * @return array> - */ - public function getNodeTypes(): array - { - return [Closure::class]; - } - - /** - * @param Closure $node - */ - public function refactor(Node $node): ?Node - { - throw new ShouldNotHappenException(sprintf( - 'The "%s" rector is deprecated as Symfony deprecated the feature in 7.4. See https://github.com/symfony/symfony/pull/62135', - self::class - )); - } -}