diff options
Diffstat (limited to 'lib/base.php')
-rw-r--r-- | lib/base.php | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/lib/base.php b/lib/base.php index 26be1161ba3..8ea164a5007 100644 --- a/lib/base.php +++ b/lib/base.php @@ -545,14 +545,9 @@ class OC { OC_Util::isSetLocaleWorking(); if (!defined('PHPUNIT_RUN')) { - $logger = \OC::$server->getLogger(); - OC\Log\ErrorHandler::setLogger($logger); - if (\OC::$server->getConfig()->getSystemValue('debug', false)) { - OC\Log\ErrorHandler::register(true); - set_exception_handler(array('OC_Template', 'printExceptionErrorPage')); - } else { - OC\Log\ErrorHandler::register(); - } + OC\Log\ErrorHandler::setLogger(\OC::$server->getLogger()); + $debug = \OC::$server->getConfig()->getSystemValue('debug', false); + OC\Log\ErrorHandler::register($debug); } // register the stream wrappers |