aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/Command/Security/ListCertificates.php6
-rw-r--r--core/register_command.php2
2 files changed, 6 insertions, 2 deletions
diff --git a/core/Command/Security/ListCertificates.php b/core/Command/Security/ListCertificates.php
index 96063fb5b61..97791956386 100644
--- a/core/Command/Security/ListCertificates.php
+++ b/core/Command/Security/ListCertificates.php
@@ -26,16 +26,20 @@ use OC\Core\Command\Base;
use OCP\ICertificate;
use OCP\ICertificateManager;
use OCP\IL10N;
+use OCP\L10N\IFactory as IL10NFactory;
use Symfony\Component\Console\Helper\Table;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
class ListCertificates extends Base {
+ protected IL10N $l;
+
public function __construct(
protected ICertificateManager $certificateManager,
- protected IL10N $l,
+ IL10NFactory $l10nFactory,
) {
parent::__construct();
+ $this->l = $l10nFactory->get('core');
}
protected function configure() {
diff --git a/core/register_command.php b/core/register_command.php
index 205ea58001b..9dde2bbc223 100644
--- a/core/register_command.php
+++ b/core/register_command.php
@@ -180,7 +180,7 @@ if ($config->getSystemValueBool('installed', false)) {
$application->add(Server::get(Command\SystemTag\Add::class));
$application->add(Server::get(Command\SystemTag\Edit::class));
- $application->add(new Command\Security\ListCertificates(\OC::$server->getCertificateManager(), \OC::$server->getL10N('core')));
+ $application->add(Server::get(Command\Security\ListCertificates::class));
$application->add(Server::get(Command\Security\ImportCertificate::class));
$application->add(Server::get(Command\Security\RemoveCertificate::class));
$application->add(Server::get(Command\Security\BruteforceAttempts::class));