]> git.mxchange.org Git - friendica.git/commitdiff
deprecate value `monolog` for config `system.logger_config`
authorArt4 <art4@wlabs.de>
Mon, 14 Apr 2025 14:36:46 +0000 (14:36 +0000)
committerArt4 <art4@wlabs.de>
Mon, 14 Apr 2025 14:36:46 +0000 (14:36 +0000)
src/Core/Logger/Factory/DelegatingLoggerFactory.php
static/defaults.config.php

index 924e4e7d1ae65e9beec5a4da460d2de80c2e5e40..2091b51bd995523ae59a269c7eea127105df824d 100644 (file)
@@ -45,6 +45,15 @@ final class DelegatingLoggerFactory implements LoggerFactory
        {
                $factoryName = $this->config->get('system', 'logger_config') ?? '';
 
+               /**
+                * @deprecated 2025.02 The value `monolog` for `system.logger_config` inside the `config/local.config.php` file is deprecated, please use `stream` or `syslog` instead.
+                */
+               if ($factoryName === 'monolog') {
+                       @trigger_error('The config `system.logger_config` with value `monolog` is deprecated since 2025.02 and will stop working in 5 months, please change the value to `stream` or `syslog` in the `config/local.config.php` file.', \E_USER_DEPRECATED);
+
+                       $factoryName = 'stream';
+               }
+
                if (!array_key_exists($factoryName, $this->factories)) {
                        return new NullLogger();
                }
index d821ff18131de85297efab43713d680e9d459430..df84d66899fb4527ada0105fddcee2c92ab1e37c 100644 (file)
@@ -334,7 +334,8 @@ return [
                'lock_driver' => '',
 
                // logger_config (String)
-               // Sets the logging adapter of Friendica globally (monolog, syslog, stream)
+               // Sets the logging adapter of Friendica globally (syslog, stream)
+               // @deprecated 2025.02 The value `monolog` is deprecated, please use `stream` or `syslog` instead.
                'logger_config' => 'stream',
 
                // syslog_flags (Integer)