diff --git a/src/Symfony/Component/HttpKernel/Log/Logger.php b/src/Symfony/Component/HttpKernel/Log/Logger.php index 8facb03c5a29..617efcf13e5a 100644 --- a/src/Symfony/Component/HttpKernel/Log/Logger.php +++ b/src/Symfony/Component/HttpKernel/Log/Logger.php @@ -42,8 +42,8 @@ public function __construct($minLevel = null, $output = 'php://stderr', callable if (null === $minLevel) { $minLevel = LogLevel::WARNING; - if (isset($_SERVER['SHELL_VERBOSITY'])) { - switch ((int) $_SERVER['SHELL_VERBOSITY']) { + if (isset($_ENV['SHELL_VERBOSITY']) || isset($_SERVER['SHELL_VERBOSITY'])) { + switch ((int) (isset($_ENV['SHELL_VERBOSITY']) ? $_ENV['SHELL_VERBOSITY'] : $_SERVER['SHELL_VERBOSITY'])) { case -1: $minLevel = LogLevel::ERROR; break; case 1: $minLevel = LogLevel::NOTICE; break; case 2: $minLevel = LogLevel::INFO; break;