fix(user_ldap): Add missing use in ajax endpoint and fix L10N injection

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
Côme Chilliet 2025-01-28 10:08:08 +01:00 committed by Andy Scherzinger
parent 7629d4df17
commit 0d35a3df02
2 changed files with 3 additions and 1 deletions

View file

@ -1,5 +1,6 @@
<?php
use OCA\User_LDAP\Exceptions\ConfigurationIssueException;
use OCA\User_LDAP\LDAP;
use OCP\ISession;
use OCP\Server;

View file

@ -15,6 +15,7 @@ use OCP\IConfig;
use OCP\IDBConnection;
use OCP\IL10N;
use OCP\Server;
use OCP\Util;
use Psr\Log\LoggerInterface;
/**
@ -159,7 +160,7 @@ class Connection extends LDAPUtility {
$this->doNotValidate = !in_array($this->configPrefix,
$helper->getServerConfigurationPrefixes());
$this->logger = Server::get(LoggerInterface::class);
$this->l10n = Server::get(IL10N::class);
$this->l10n = Util::getL10N('user_ldap');
}
public function __destruct() {