From 126c32313838988a527d4980384a561c20fd31f0 Mon Sep 17 00:00:00 2001 From: Elze Kool Date: Tue, 19 Mar 2024 09:35:49 +0100 Subject: [PATCH] Do not log info messages when verbosity is quiet Depending on the module and exact situation config settings can contain sensitive information which is outputted to the console. As this is an info message there is no way to supress this by default. Only log info messages when verbosity is not set to quiet to allow suppression --- Model/Logging.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Model/Logging.php b/Model/Logging.php index fe7dd41..424404f 100644 --- a/Model/Logging.php +++ b/Model/Logging.php @@ -57,6 +57,8 @@ public function logComment($message, $nest = 0) public function logInfo($message, $nest = 0) { - $this->log($message, $this::LEVEL_INFO, $nest); + if ($this->level > OutputInterface::VERBOSITY_QUIET) { + $this->log($message, $this::LEVEL_INFO, $nest); + } } }