merged branch tyx/fix/form-profiling (PR #9137)
This PR was merged into the master branch. Discussion ---------- [Form] form_debug.xml should be loaded only if form config is enabled | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | - Explication here:1972a91653 (commitcomment-4187567)
Commits -------b668e24
form_debug.xml should be loaded only if form config is enabled
This commit is contained in:
commit
9dffa6fdb8
@ -30,6 +30,8 @@ use Symfony\Component\Config\FileLocator;
|
||||
*/
|
||||
class FrameworkExtension extends Extension
|
||||
{
|
||||
private $formConfigEnabled = false;
|
||||
|
||||
/**
|
||||
* Responds to the app.config configuration parameter.
|
||||
*
|
||||
@ -90,6 +92,7 @@ class FrameworkExtension extends Extension
|
||||
}
|
||||
|
||||
if ($this->isConfigEnabled($container, $config['form'])) {
|
||||
$this->formConfigEnabled = true;
|
||||
$this->registerFormConfiguration($config, $container, $loader);
|
||||
$config['validation']['enabled'] = true;
|
||||
}
|
||||
@ -218,7 +221,10 @@ class FrameworkExtension extends Extension
|
||||
return;
|
||||
}
|
||||
|
||||
if (true === $this->formConfigEnabled) {
|
||||
$loader->load('form_debug.xml');
|
||||
}
|
||||
|
||||
$loader->load('profiling.xml');
|
||||
$loader->load('collectors.xml');
|
||||
|
||||
|
Reference in New Issue
Block a user