summaryrefslogtreecommitdiffstats
path: root/lib/base.php
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2016-04-18 22:30:01 +0200
committerThomas Müller <thomas.mueller@tmit.eu>2016-04-18 22:30:01 +0200
commitc609abf07522c9e1c90811f01e232488492e45b3 (patch)
tree39267474806655812836cfe4c2bf472686182b3a /lib/base.php
parent51975d360a93daba3b2681136a77b8d7078719e9 (diff)
downloadnextcloud-server-c609abf07522c9e1c90811f01e232488492e45b3.tar.gz
nextcloud-server-c609abf07522c9e1c90811f01e232488492e45b3.zip
In case of fatal php errors and other unhandled exceptions no html error page is expected to be displayed in the console
Diffstat (limited to 'lib/base.php')
-rw-r--r--lib/base.php11
1 files changed, 3 insertions, 8 deletions
diff --git a/lib/base.php b/lib/base.php
index 27967588360..708229a8e7f 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