From 1316e98b893247fd33e3118d194725e776ede44f Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Sun, 3 Sep 2017 19:39:07 +0200 Subject: [PATCH 1/3] Deprecated the web_profiler.position option --- .../WebProfilerBundle/DependencyInjection/Configuration.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php b/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php index 957a683ca3563..8787e53cbe381 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php +++ b/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php @@ -39,6 +39,12 @@ public function getConfigTreeBuilder() ->booleanNode('toolbar')->defaultFalse()->end() ->scalarNode('position') ->defaultValue('bottom') + ->beforeNormalization() + ->ifTrue(function ($v) { return null !== $v; }) + ->then(function () { + @trigger_error('The "web_profiler.position" configuration key has been deprecated in Symfony 3.4 and it will be removed in 4.0.', E_USER_DEPRECATED); + }) + ->end() ->validate() ->ifNotInArray(array('bottom', 'top')) ->thenInvalid('The CSS position %s is not supported') From f2db295aa8cc2f8d7b16a75136f5fd60b4f41378 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Sun, 3 Sep 2017 19:41:48 +0200 Subject: [PATCH 2/3] Added the missing entry in the CHANGELOG --- src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md b/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md index dafd4c46bb0fc..c081103a8071e 100644 --- a/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md +++ b/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md @@ -53,6 +53,8 @@ CHANGELOG `EventDispatcherDebugCommand`, `RouterDebugCommand`, `RouterMatchCommand`, `TranslationDebugCommand`, `TranslationUpdateCommand`, `XliffLintCommand` and `YamlLintCommand` classes have been marked as final + * Deprecated the `web_profiler.position` config option (in Symfony 4.0 the toolbar + will always be displayed at the bottom). 3.3.0 ----- From 1a32a731c1be11d5756ff6d09ca8ef19184c23cb Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Thu, 7 Sep 2017 16:58:22 +0200 Subject: [PATCH 3/3] Use the new setDeprecated() method --- .../DependencyInjection/Configuration.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php b/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php index 8787e53cbe381..e07b28925de41 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php +++ b/src/Symfony/Bundle/WebProfilerBundle/DependencyInjection/Configuration.php @@ -39,12 +39,7 @@ public function getConfigTreeBuilder() ->booleanNode('toolbar')->defaultFalse()->end() ->scalarNode('position') ->defaultValue('bottom') - ->beforeNormalization() - ->ifTrue(function ($v) { return null !== $v; }) - ->then(function () { - @trigger_error('The "web_profiler.position" configuration key has been deprecated in Symfony 3.4 and it will be removed in 4.0.', E_USER_DEPRECATED); - }) - ->end() + ->setDeprecated('The "web_profiler.position" configuration key has been deprecated in Symfony 3.4 and it will be removed in 4.0.') ->validate() ->ifNotInArray(array('bottom', 'top')) ->thenInvalid('The CSS position %s is not supported') pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy