summaryrefslogtreecommitdiffstats
path: root/lib/private
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private')
-rw-r--r--lib/private/Log.php4
-rw-r--r--lib/private/Log/File.php (renamed from lib/private/Log/Owncloud.php)2
-rw-r--r--lib/private/Log/Syslog.php2
-rw-r--r--lib/private/Server.php5
4 files changed, 8 insertions, 5 deletions
diff --git a/lib/private/Log.php b/lib/private/Log.php
index 59233cf5c12..2d06e62f54c 100644
--- a/lib/private/Log.php
+++ b/lib/private/Log.php
@@ -103,7 +103,9 @@ class Log implements ILogger {
// FIXME: Add this for backwards compatibility, should be fixed at some point probably
if($logger === null) {
- $this->logger = 'OC\\Log\\'.ucfirst($this->config->getValue('log_type', 'owncloud'));
+ // TODO: Drop backwards compatibility for config in the future
+ $logType = $this->config->getValue('log_type', 'file');
+ $this->logger = 'OC\\Log\\'.ucfirst($logType=='owncloud' ? 'file' : $logType);
call_user_func(array($this->logger, 'init'));
} else {
$this->logger = $logger;
diff --git a/lib/private/Log/Owncloud.php b/lib/private/Log/File.php
index 2cc70015e3c..a406dd83952 100644
--- a/lib/private/Log/Owncloud.php
+++ b/lib/private/Log/File.php
@@ -39,7 +39,7 @@ namespace OC\Log;
* Log is saved at data/nextcloud.log (on default)
*/
-class Owncloud {
+class File {
static protected $logFile;
/**
diff --git a/lib/private/Log/Syslog.php b/lib/private/Log/Syslog.php
index c6ea0a40350..73978250310 100644
--- a/lib/private/Log/Syslog.php
+++ b/lib/private/Log/Syslog.php
@@ -38,7 +38,7 @@ class Syslog {
* Init class data
*/
public static function init() {
- openlog(\OC::$server->getSystemConfig()->getValue("syslog_tag", "ownCloud"), LOG_PID | LOG_CONS, LOG_USER);
+ openlog(\OC::$server->getSystemConfig()->getValue("syslog_tag", "Nextcloud"), LOG_PID | LOG_CONS, LOG_USER);
// Close at shutdown
register_shutdown_function('closelog');
}
diff --git a/lib/private/Server.php b/lib/private/Server.php
index de2970d9bfa..bc1e526786d 100644
--- a/lib/private/Server.php
+++ b/lib/private/Server.php
@@ -364,8 +364,9 @@ class Server extends ServerContainer implements IServerContainer {
);
});
$this->registerService('Logger', function (Server $c) {
- $logClass = $c->query('AllConfig')->getSystemValue('log_type', 'owncloud');
- $logger = 'OC\\Log\\' . ucfirst($logClass);
+ $logClass = $c->query('AllConfig')->getSystemValue('log_type', 'file');
+ // TODO: Drop backwards compatibility for config in the future
+ $logger = 'OC\\Log\\' . ucfirst($logClass=='owncloud' ? 'file' : $logClass);
call_user_func(array($logger, 'init'));
return new Log($logger);