From 3b1ce79c62d9e1ad31074512db4d3777c6b26912 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Wed, 18 Dec 2024 08:23:33 +0100 Subject: [PATCH] - --- .../Resources/config/routing/errors.yml | 7 +++ .../Resources/config/routing/webhook.yml | 5 ++ .../XmlCompleteConfigurationTest.php | 3 + .../XmlCustomAuthenticatorTest.php | 3 + .../XmlCustomProviderTest.php | 3 + .../xml/customTemplateEscapingGuesser.xml | 10 ---- .../Fixtures/xml/empty.xml | 10 ---- .../Fixtures/xml/extra.xml | 12 ---- .../Fixtures/xml/formats.xml | 12 ---- .../DependencyInjection/Fixtures/xml/full.xml | 19 ------- .../Fixtures/xml/mailer.xml | 11 ---- .../Fixtures/xml/templateClass.xml | 10 ---- .../DependencyInjection/TwigExtensionTest.php | 7 +-- .../Resources/config/routing/profiler.xml | 55 ------------------- .../Resources/config/routing/profiler.yml | 47 ++++++++++++++++ .../Resources/config/routing/wdt.xml | 14 ----- .../Resources/config/routing/wdt.yml | 7 +++ .../Functional/WebProfilerBundleKernel.php | 4 +- .../DependencyInjection/Dumper/XmlDumper.php | 4 -- .../Extension/ExtensionTrait.php | 2 +- .../Loader/XmlFileLoader.php | 5 +- .../Tests/Dumper/XmlDumperTest.php | 3 - src/Symfony/Component/HttpKernel/Kernel.php | 2 +- .../Component/HttpKernel/Tests/KernelTest.php | 4 +- .../Mapping/Loader/XmlFileLoader.php | 5 +- .../Component/Validator/ValidatorBuilder.php | 2 +- 26 files changed, 92 insertions(+), 174 deletions(-) create mode 100644 src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/errors.yml create mode 100644 src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/webhook.yml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/customTemplateEscapingGuesser.xml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/empty.xml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/extra.xml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/formats.xml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/full.xml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/mailer.xml delete mode 100644 src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/templateClass.xml delete mode 100644 src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.xml create mode 100644 src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.yml delete mode 100644 src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.xml create mode 100644 src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.yml diff --git a/src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/errors.yml b/src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/errors.yml new file mode 100644 index 0000000000000..9d91b25045517 --- /dev/null +++ b/src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/errors.yml @@ -0,0 +1,7 @@ +_preview_error: + path: /{code}.{_format} + controller: error_controller::preview + defaults: + _format: html + requirements: + code: \d+ diff --git a/src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/webhook.yml b/src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/webhook.yml new file mode 100644 index 0000000000000..9de14df3b00fd --- /dev/null +++ b/src/Symfony/Bundle/FrameworkBundle/Resources/config/routing/webhook.yml @@ -0,0 +1,5 @@ +_webhook_controller: + path: /{type} + controller: webhook.controller::handle + requirements: + type: .+ diff --git a/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCompleteConfigurationTest.php b/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCompleteConfigurationTest.php index 2624adc9bebcd..21998402fe531 100644 --- a/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCompleteConfigurationTest.php +++ b/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCompleteConfigurationTest.php @@ -15,6 +15,9 @@ use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +/** + * @group legacy + */ class XmlCompleteConfigurationTest extends CompleteConfigurationTestCase { public function testFirewallPatterns() diff --git a/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomAuthenticatorTest.php b/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomAuthenticatorTest.php index e57cda13ff78d..2a30a7c219430 100644 --- a/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomAuthenticatorTest.php +++ b/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomAuthenticatorTest.php @@ -18,6 +18,9 @@ use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +/** + * @group legacy + */ class XmlCustomAuthenticatorTest extends TestCase { /** diff --git a/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomProviderTest.php b/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomProviderTest.php index a3f59fc299a24..455d120ce6eb8 100644 --- a/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomProviderTest.php +++ b/src/Symfony/Bundle/SecurityBundle/Tests/DependencyInjection/XmlCustomProviderTest.php @@ -18,6 +18,9 @@ use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +/** + * @group legacy + */ class XmlCustomProviderTest extends TestCase { /** diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/customTemplateEscapingGuesser.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/customTemplateEscapingGuesser.xml deleted file mode 100644 index f72bed9d14884..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/customTemplateEscapingGuesser.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/empty.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/empty.xml deleted file mode 100644 index f3b51fa24201c..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/empty.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/extra.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/extra.xml deleted file mode 100644 index f1cf8985329d0..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/extra.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - namespaced_path3 - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/formats.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/formats.xml deleted file mode 100644 index fa888b30acf61..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/formats.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/full.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/full.xml deleted file mode 100644 index 528a466b0452c..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/full.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - MyBundle::form.html.twig - - @@qux - 3.14 - path1 - path2 - namespaced_path1 - namespaced_path2 - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/mailer.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/mailer.xml deleted file mode 100644 index 25c2a9453663e..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/mailer.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/templateClass.xml b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/templateClass.xml deleted file mode 100644 index a735ed8da258e..0000000000000 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/Fixtures/xml/templateClass.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - diff --git a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/TwigExtensionTest.php b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/TwigExtensionTest.php index ffe772a28861d..cd7899d6720ee 100644 --- a/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/TwigExtensionTest.php +++ b/src/Symfony/Bundle/TwigBundle/Tests/DependencyInjection/TwigExtensionTest.php @@ -20,7 +20,6 @@ use Symfony\Component\DependencyInjection\Compiler\PassConfig; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use Symfony\Component\DependencyInjection\Loader\XmlFileLoader; use Symfony\Component\DependencyInjection\Loader\YamlFileLoader; use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; use Symfony\Component\DependencyInjection\Reference; @@ -41,7 +40,7 @@ public function testLoadEmptyConfiguration() $container->loadFromExtension('twig'); $this->compileContainer($container); - $this->assertEquals(Environment::class, $container->getDefinition('twig')->getClass(), '->load() loads the twig.xml file'); + $this->assertEquals(Environment::class, $container->getDefinition('twig')->getClass(), '->load() loads the twig.yml file'); $this->assertContains('form_div_layout.html.twig', $container->getParameter('twig.form.resources'), '->load() includes default template for form resources'); @@ -66,7 +65,7 @@ public function testLoadFullConfiguration(string $format) $this->loadFromFile($container, 'full', $format); $this->compileContainer($container); - $this->assertEquals(Environment::class, $container->getDefinition('twig')->getClass(), '->load() loads the twig.xml file'); + $this->assertEquals(Environment::class, $container->getDefinition('twig')->getClass(), \sprintf('->load() loads the twig.%s file', $format)); // Form resources $resources = $container->getParameter('twig.form.resources'); @@ -234,7 +233,6 @@ public static function getFormats(): array return [ ['php'], ['yml'], - ['xml'], ]; } @@ -347,7 +345,6 @@ private function loadFromFile(ContainerBuilder $container, string $file, string $loader = match ($format) { 'php' => new PhpFileLoader($container, $locator), - 'xml' => new XmlFileLoader($container, $locator), 'yml' => new YamlFileLoader($container, $locator), }; diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.xml b/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.xml deleted file mode 100644 index 363b15d872b0c..0000000000000 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - web_profiler.controller.profiler::homeAction - - - - web_profiler.controller.profiler::searchAction - - - - web_profiler.controller.profiler::searchBarAction - - - - web_profiler.controller.profiler::phpinfoAction - - - - web_profiler.controller.profiler::xdebugAction - - - - web_profiler.controller.profiler::fontAction - - - - web_profiler.controller.profiler::searchResultsAction - - - - web_profiler.controller.profiler::openAction - - - - web_profiler.controller.profiler::panelAction - - - - web_profiler.controller.router::panelAction - - - - web_profiler.controller.exception_panel::body - - - - web_profiler.controller.exception_panel::stylesheet - - - diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.yml b/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.yml new file mode 100644 index 0000000000000..08fb1e1a27099 --- /dev/null +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/profiler.yml @@ -0,0 +1,47 @@ +_profiler_home: + path: / + controller: web_profiler.controller.profiler::homeAction + +_profiler_search: + path: /search + controller: web_profiler.controller.profiler::searchAction + +_profiler_search_bar: + path: /search_bar + controller: web_profiler.controller.profiler::searchBarAction + +_profiler_phpinfo: + path: /phpinfo + controller: web_profiler.controller.profiler::phpinfoAction + +_profiler_xdebug: + path: /xdebug + controller: web_profiler.controller.profiler::xdebugAction + +_profiler_font: + path: /font/{fontName}.woff2 + controller: web_profiler.controller.profiler::fontAction + +_profiler_search_results: + path: /{token}/search/results + controller: web_profiler.controller.profiler::searchResultsAction + +_profiler_open_file: + path: /open + controller: web_profiler.controller.profiler::openAction + +_profiler: + path: /{token} + controller: web_profiler.controller.profiler::panelAction + +_profiler_router: + path: /{token}/router + controller: web_profiler.controller.router::panelAction + +_profiler_exception: + path: /{token}/exception + controller: web_profiler.controller.exception_panel::body + +_profiler_exception_css: + path: /{token}/exception.css + controller: web_profiler.controller.exception_panel::stylesheet diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.xml b/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.xml deleted file mode 100644 index 26bbd96455adf..0000000000000 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - web_profiler.controller.profiler::toolbarStylesheetAction - - - - web_profiler.controller.profiler::toolbarAction - - diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.yml b/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.yml new file mode 100644 index 0000000000000..0e1159bad0a60 --- /dev/null +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/config/routing/wdt.yml @@ -0,0 +1,7 @@ +_wdt_stylesheet: + path: /styles.css + controller: web_profiler.controller.profiler::toolbarStylesheetAction + +_wdt: + path: /{token} + controller: web_profiler.controller.profiler::toolbarAction diff --git a/src/Symfony/Bundle/WebProfilerBundle/Tests/Functional/WebProfilerBundleKernel.php b/src/Symfony/Bundle/WebProfilerBundle/Tests/Functional/WebProfilerBundleKernel.php index 6438960287411..58158357d3aa0 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Tests/Functional/WebProfilerBundleKernel.php +++ b/src/Symfony/Bundle/WebProfilerBundle/Tests/Functional/WebProfilerBundleKernel.php @@ -43,8 +43,8 @@ public function registerBundles(): iterable protected function configureRoutes(RoutingConfigurator $routes): void { - $routes->import(__DIR__.'/../../Resources/config/routing/profiler.xml')->prefix('/_profiler'); - $routes->import(__DIR__.'/../../Resources/config/routing/wdt.xml')->prefix('/_wdt'); + $routes->import(__DIR__.'/../../Resources/config/routing/profiler.yml')->prefix('/_profiler'); + $routes->import(__DIR__.'/../../Resources/config/routing/wdt.yml')->prefix('/_wdt'); $routes->add('_', '/')->controller('kernel::homepageController'); } diff --git a/src/Symfony/Component/DependencyInjection/Dumper/XmlDumper.php b/src/Symfony/Component/DependencyInjection/Dumper/XmlDumper.php index efa38f55e0df0..91ed94ff78b42 100644 --- a/src/Symfony/Component/DependencyInjection/Dumper/XmlDumper.php +++ b/src/Symfony/Component/DependencyInjection/Dumper/XmlDumper.php @@ -30,8 +30,6 @@ * * @author Fabien Potencier * @author Martin HasoĊˆ - * - * @deprecated since Symfony 7.3 */ class XmlDumper extends Dumper { @@ -40,8 +38,6 @@ class XmlDumper extends Dumper public function __construct( protected ContainerBuilder $container, ) { - trigger_deprecation('symfony/dependency-injection', '7.3', \sprintf('The "%s" class is deprecated.', __CLASS__)); - parent::__construct($container); } diff --git a/src/Symfony/Component/DependencyInjection/Extension/ExtensionTrait.php b/src/Symfony/Component/DependencyInjection/Extension/ExtensionTrait.php index 0bb008860fe01..c9d430e5a6f85 100644 --- a/src/Symfony/Component/DependencyInjection/Extension/ExtensionTrait.php +++ b/src/Symfony/Component/DependencyInjection/Extension/ExtensionTrait.php @@ -55,7 +55,7 @@ private function createContainerLoader(ContainerBuilder $container, string $env, $buildDir = $container->getParameter('kernel.build_dir'); $locator = new FileLocator(); $resolver = new LoaderResolver([ - new XmlFileLoader($container, $locator, $env, $prepend), + new XmlFileLoader($container, $locator, $env, $prepend, false, false), new YamlFileLoader($container, $locator, $env, $prepend), new IniFileLoader($container, $locator, $env), new PhpFileLoader($container, $locator, $env, new ConfigBuilderGenerator($buildDir), $prepend), diff --git a/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php b/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php index c523183278c8f..e0e93cee1cae9 100644 --- a/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php +++ b/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php @@ -49,8 +49,11 @@ public function __construct( FileLocatorInterface $locator, ?string $env = null, protected bool $prepend = false, + bool $triggerDeprecation = true, ) { - trigger_deprecation('symfony/dependency-injection', '7.3', \sprintf('The "%s" class is deprecated.', __CLASS__)); + if ($triggerDeprecation) { + trigger_deprecation('symfony/dependency-injection', '7.3', \sprintf('The "%s" class is deprecated.', __CLASS__)); + } parent::__construct($container, $locator, $env, $prepend); } diff --git a/src/Symfony/Component/DependencyInjection/Tests/Dumper/XmlDumperTest.php b/src/Symfony/Component/DependencyInjection/Tests/Dumper/XmlDumperTest.php index f43bab49d150c..548e5a18b27ec 100644 --- a/src/Symfony/Component/DependencyInjection/Tests/Dumper/XmlDumperTest.php +++ b/src/Symfony/Component/DependencyInjection/Tests/Dumper/XmlDumperTest.php @@ -30,9 +30,6 @@ use Symfony\Component\DependencyInjection\Tests\Fixtures\FooUnitEnum; use Symfony\Component\DependencyInjection\Tests\Fixtures\FooWithAbstractArgument; -/** - * @group legacy - */ class XmlDumperTest extends TestCase { protected static string $fixturesPath; diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index ec5e3b0df3f20..0a1d4978f5dcd 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -714,7 +714,7 @@ protected function getContainerLoader(ContainerInterface $container): Delegating $env = $this->getEnvironment(); $locator = new FileLocator($this); $resolver = new LoaderResolver([ - new XmlFileLoader($container, $locator, $env), + new XmlFileLoader($container, $locator, $env, false, false), new YamlFileLoader($container, $locator, $env), new IniFileLoader($container, $locator, $env), new PhpFileLoader($container, $locator, $env, class_exists(ConfigBuilderGenerator::class) ? new ConfigBuilderGenerator($this->getBuildDir()) : null), diff --git a/src/Symfony/Component/HttpKernel/Tests/KernelTest.php b/src/Symfony/Component/HttpKernel/Tests/KernelTest.php index f650c33ee0214..1e6506e2fbba1 100644 --- a/src/Symfony/Component/HttpKernel/Tests/KernelTest.php +++ b/src/Symfony/Component/HttpKernel/Tests/KernelTest.php @@ -264,7 +264,7 @@ public function testLocateResourceThrowsExceptionWhenNameIsUnsafe() public function testLocateResourceThrowsExceptionWhenBundleDoesNotExist() { $this->expectException(\InvalidArgumentException::class); - $this->getKernel()->locateResource('@FooBundle/config/routing.xml'); + $this->getKernel()->locateResource('@FooBundle/config/routing.yml'); } public function testLocateResourceThrowsExceptionWhenResourceDoesNotExist() @@ -277,7 +277,7 @@ public function testLocateResourceThrowsExceptionWhenResourceDoesNotExist() ->willReturn($this->getBundle(__DIR__.'/Fixtures/Bundle1Bundle')) ; - $kernel->locateResource('@Bundle1Bundle/config/routing.xml'); + $kernel->locateResource('@Bundle1Bundle/config/routing.yml'); } public function testLocateResourceReturnsTheFirstThatMatches() diff --git a/src/Symfony/Component/Validator/Mapping/Loader/XmlFileLoader.php b/src/Symfony/Component/Validator/Mapping/Loader/XmlFileLoader.php index 0258591cfea51..1fb5749a8b827 100644 --- a/src/Symfony/Component/Validator/Mapping/Loader/XmlFileLoader.php +++ b/src/Symfony/Component/Validator/Mapping/Loader/XmlFileLoader.php @@ -34,8 +34,11 @@ class XmlFileLoader extends FileLoader public function __construct( protected string $file, + bool $triggerDeprecation = true, ) { - trigger_deprecation('symfony/validator', '7.3', \sprintf('The "%s" class is deprecated.', __CLASS__)); + if ($triggerDeprecation) { + trigger_deprecation('symfony/validator', '7.3', \sprintf('The "%s" class is deprecated.', __CLASS__)); + } parent::__construct($file); } diff --git a/src/Symfony/Component/Validator/ValidatorBuilder.php b/src/Symfony/Component/Validator/ValidatorBuilder.php index 83e543b8fe053..91975afbd2dbb 100644 --- a/src/Symfony/Component/Validator/ValidatorBuilder.php +++ b/src/Symfony/Component/Validator/ValidatorBuilder.php @@ -310,7 +310,7 @@ public function getLoaders(): array $loaders = []; foreach ($this->xmlMappings as $xmlMapping) { - $loaders[] = new XmlFileLoader($xmlMapping); + $loaders[] = new XmlFileLoader($xmlMapping, false); } foreach ($this->yamlMappings as $yamlMappings) {