summaryrefslogtreecommitdiffstats
path: root/lib/base.php
diff options
context:
space:
mode:
authorJose Quinteiro <github@quinteiro.org>2020-03-09 12:01:05 -0700
committerJose Quinteiro <github@quinteiro.org>2020-03-09 12:05:21 -0700
commit6cf679e04ec4edab71871d88640adc933df08b6b (patch)
tree3582151a9169c5c8d402185fab38243c318c3b7d /lib/base.php
parent1f7cb027a4f3169274f6b5861d6d55e1e21ee002 (diff)
downloadnextcloud-server-6cf679e04ec4edab71871d88640adc933df08b6b.tar.gz
nextcloud-server-6cf679e04ec4edab71871d88640adc933df08b6b.zip
Set error_logging correctly. Fixes #19847
Don't override the error_logging setting from php.ini unless we're debugging. Signed-off-by: Jose Quinteiro <github@quinteiro.org>
Diffstat (limited to 'lib/base.php')
-rw-r--r--lib/base.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/base.php b/lib/base.php
index 1d944685654..e0aae986f8f 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -602,8 +602,12 @@ class OC {
\OC::$server->getEventLogger()->log('autoloader', 'Autoloader', $loaderStart, $loaderEnd);
\OC::$server->getEventLogger()->start('boot', 'Initialize');
+ // Override php.ini and log everything if we're troubleshooting
+ if (self::$config->getValue('loglevel') === ILogger::DEBUG) {
+ error_reporting(E_ALL | E_DEPRECATED);
+ }
+
// Don't display errors and log them
- error_reporting(E_ALL | E_STRICT);
@ini_set('display_errors', '0');
@ini_set('log_errors', '1');