change deprecated logging method

Signed-off-by: Jonas Sulzer <jonas@violoncello.ch>
This commit is contained in:
Jonas Sulzer
2018-12-27 13:02:49 +01:00
parent a67e3e08e0
commit db5ab31ee4
4 changed files with 12 additions and 12 deletions

View File

@@ -42,9 +42,9 @@ class OC_User_SMB extends \OCA\user_external\Base{
$command = self::SMBCLIENT.' '.escapeshellarg('//' . $this->host . '/dummy').' -U'.$uidEscaped.'%'.$password;
$lastline = exec($command, $output, $retval);
if ($retval === 127) {
OCP\Util::writeLog(
'user_external', 'ERROR: smbclient executable missing',
OCP\Util::ERROR
OC::$server->getLogger()->error(
'ERROR: smbclient executable missing',
['app' => 'user_external']
);
return false;
} else if (strpos($lastline, self::LOGINERROR) !== false) {
@@ -55,9 +55,9 @@ class OC_User_SMB extends \OCA\user_external\Base{
goto login;
} else if ($retval !== 0) {
//some other error
OCP\Util::writeLog(
'user_external', 'ERROR: smbclient error: ' . trim($lastline),
OCP\Util::ERROR
OC::$server->getLogger()->error(
'ERROR: smbclient error: ' . trim($lastline),
['app' => 'user_external']
);
return false;
} else {