From: Bart Visscher Date: Thu, 27 Jun 2013 20:01:52 +0000 (+0200) Subject: Fix review points X-Git-Tag: v6.0.0alpha2~569^2~2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=fb80cbd4997625c2d87457d5ba0b908206474d4d;p=nextcloud-server.git Fix review points --- diff --git a/lib/log.php b/lib/log.php index 2e26ccad2da..8c157d003cf 100644 --- a/lib/log.php +++ b/lib/log.php @@ -19,6 +19,8 @@ namespace OC; */ class Log { + private $logClass; + /** * System is unusable. * @@ -111,8 +113,8 @@ class Log { } public function __construct() { - $this->log_class = 'OC_Log_'.ucfirst(\OC_Config::getValue('log_type', 'owncloud')); - call_user_func(array($this->log_class, 'init')); + $this->logClass = 'OC_Log_'.ucfirst(\OC_Config::getValue('log_type', 'owncloud')); + call_user_func(array($this->logClass, 'init')); } /** @@ -122,13 +124,13 @@ class Log { * @param string $message * @param array $context */ - protected function log($level, $message, array $context = array()) { + public function log($level, $message, array $context = array()) { if (isset($context['app'])) { $app = $context['app']; } else { $app = 'no app in context'; } - $log_class=$this->log_class; - $log_class::write($app, $message, $level); + $logClass=$this->logClass; + $logClass::write($app, $message, $level); } }