diff options
author | Lukas Reschke <lukas@owncloud.com> | 2015-05-05 12:34:22 +0200 |
---|---|---|
committer | Lukas Reschke <lukas@owncloud.com> | 2015-05-06 10:38:28 +0200 |
commit | ecf8343905491c2addd8aca30aa2533b78a45c65 (patch) | |
tree | 16e81687c1612aff44965ea4b33118dcd6e3acad | |
parent | 053ac112731c38c139615f3eab0862b9d53b8122 (diff) | |
download | nextcloud-server-ecf8343905491c2addd8aca30aa2533b78a45c65.tar.gz nextcloud-server-ecf8343905491c2addd8aca30aa2533b78a45c65.zip |
Don't display errors and log them
Fixes https://github.com/owncloud/core/issues/16014
-rw-r--r-- | lib/base.php | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/base.php b/lib/base.php index 86097438d57..27b5174c88f 100644 --- a/lib/base.php +++ b/lib/base.php @@ -489,12 +489,11 @@ class OC { \OC::$server->getEventLogger()->log('autoloader', 'Autoloader', $loaderStart, $loaderEnd); \OC::$server->getEventLogger()->start('boot', 'Initialize'); - // set some stuff - //ob_start(); + // Don't display errors and log them error_reporting(E_ALL | E_STRICT); - if (defined('DEBUG') && DEBUG) { - ini_set('display_errors', 1); - } + @ini_set('display_errors', 0); + @ini_set('log_errors', 1); + self::$CLI = (php_sapi_name() == 'cli'); date_default_timezone_set('UTC'); |