summaryrefslogtreecommitdiff
path: root/app/ServiceProvider/LoggingProvider.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/ServiceProvider/LoggingProvider.php')
-rw-r--r--app/ServiceProvider/LoggingProvider.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/app/ServiceProvider/LoggingProvider.php b/app/ServiceProvider/LoggingProvider.php
index 93f55a9c..f5e70381 100644
--- a/app/ServiceProvider/LoggingProvider.php
+++ b/app/ServiceProvider/LoggingProvider.php
@@ -13,8 +13,11 @@ class LoggingProvider implements ServiceProviderInterface
public function register(Container $container)
{
$logger = new Logger('app');
- $logger->pushHandler(new StreamHandler(__DIR__.'/../../data/debug.log', Logger::DEBUG));
- $logger->pushHandler(new SyslogHandler('kanboard', LOG_USER, Logger::DEBUG));
+ $logger->pushHandler(new SyslogHandler('kanboard', LOG_USER, Logger::INFO));
+
+ if (DEBUG) {
+ $logger->pushHandler(new StreamHandler(__DIR__.'/../../data/debug.log', Logger::DEBUG));
+ }
$container['logger'] = $logger;
}