aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/User
diff options
context:
space:
mode:
authorF. E Noel Nfebe <fenn25.fn@gmail.com>2024-02-14 10:47:22 +0100
committerGitHub <noreply@github.com>2024-02-14 10:47:22 +0100
commit3fb1674251569e4972554f6500a66986eedfebf3 (patch)
tree38bfb200873e64f43300126a3734dc2a2129af20 /lib/private/User
parent0369e4c3021142091a9fd681df25522bdf880507 (diff)
parentc0ce272e9c3a94ff98081c4f90a31ca611d28323 (diff)
downloadnextcloud-server-3fb1674251569e4972554f6500a66986eedfebf3.tar.gz
nextcloud-server-3fb1674251569e4972554f6500a66986eedfebf3.zip
Merge pull request #43461 from nextcloud/fix/get-rid-of-getlogger
chore: Migrate away from OC::$server->getLogger
Diffstat (limited to 'lib/private/User')
-rw-r--r--lib/private/User/Manager.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/private/User/Manager.php b/lib/private/User/Manager.php
index 25a75078503..66a9529483e 100644
--- a/lib/private/User/Manager.php
+++ b/lib/private/User/Manager.php
@@ -56,6 +56,7 @@ use OCP\User\Backend\ISearchKnownUsersBackend;
use OCP\User\Events\BeforeUserCreatedEvent;
use OCP\User\Events\UserCreatedEvent;
use OCP\UserInterface;
+use Psr\Log\LoggerInterface;
/**
* Class Manager
@@ -235,7 +236,7 @@ class Manager extends PublicEmitter implements IUserManager {
$result = $this->checkPasswordNoLogging($loginName, $password);
if ($result === false) {
- \OC::$server->getLogger()->warning('Login failed: \''. $loginName .'\' (Remote IP: \''. \OC::$server->getRequest()->getRemoteAddress(). '\')', ['app' => 'core']);
+ \OCP\Server::get(LoggerInterface::class)->warning('Login failed: \''. $loginName .'\' (Remote IP: \''. \OC::$server->getRequest()->getRemoteAddress(). '\')', ['app' => 'core']);
}
return $result;