summaryrefslogtreecommitdiffstats
path: root/lib/private/Repair.php
diff options
context:
space:
mode:
authorCôme Chilliet <come.chilliet@nextcloud.com>2022-03-17 17:26:27 +0100
committerCôme Chilliet <come.chilliet@nextcloud.com>2022-03-24 16:21:25 +0100
commitea23523c70ee562092510ccf88e7aa469aae9ce6 (patch)
treeda0ce15036d2f7b82ef1a0e44adb497c8e951cb3 /lib/private/Repair.php
parenteb961e47003ee5b6d7328caf10ecd5f53cc93666 (diff)
downloadnextcloud-server-ea23523c70ee562092510ccf88e7aa469aae9ce6.tar.gz
nextcloud-server-ea23523c70ee562092510ccf88e7aa469aae9ce6.zip
Adapt more code to migration to LoggerInterface
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'lib/private/Repair.php')
-rw-r--r--lib/private/Repair.php9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/private/Repair.php b/lib/private/Repair.php
index 408d0f1b7aa..d5856f0e7aa 100644
--- a/lib/private/Repair.php
+++ b/lib/private/Repair.php
@@ -93,13 +93,12 @@ class Repair implements IOutput {
/** @var string */
private $currentStep;
- private $logger;
+ private LoggerInterface $logger;
/**
* Creates a new repair step runner
*
* @param IRepairStep[] $repairSteps array of RepairStep instances
- * @param EventDispatcherInterface $dispatcher
*/
public function __construct(array $repairSteps, EventDispatcherInterface $dispatcher, LoggerInterface $logger) {
$this->repairSteps = $repairSteps;
@@ -171,7 +170,7 @@ class Repair implements IOutput {
*/
public static function getRepairSteps() {
return [
- new Collation(\OC::$server->getConfig(), \OC::$server->getLogger(), \OC::$server->getDatabaseConnection(), false),
+ new Collation(\OC::$server->getConfig(), \OC::$server->get(LoggerInterface::class), \OC::$server->getDatabaseConnection(), false),
new RepairMimeTypes(\OC::$server->getConfig(), \OC::$server->getDatabaseConnection()),
new CleanTags(\OC::$server->getDatabaseConnection(), \OC::$server->getUserManager()),
new RepairInvalidShares(\OC::$server->getConfig(), \OC::$server->getDatabaseConnection()),
@@ -197,7 +196,7 @@ class Repair implements IOutput {
new ClearGeneratedAvatarCache(\OC::$server->getConfig(), \OC::$server->query(AvatarManager::class)),
new AddPreviewBackgroundCleanupJob(\OC::$server->getJobList()),
new AddCleanupUpdaterBackupsJob(\OC::$server->getJobList()),
- new CleanupCardDAVPhotoCache(\OC::$server->getConfig(), \OC::$server->getAppDataDir('dav-photocache'), \OC::$server->getLogger()),
+ new CleanupCardDAVPhotoCache(\OC::$server->getConfig(), \OC::$server->getAppDataDir('dav-photocache'), \OC::$server->get(LoggerInterface::class)),
new AddClenupLoginFlowV2BackgroundJob(\OC::$server->getJobList()),
new RemoveLinkShares(\OC::$server->getDatabaseConnection(), \OC::$server->getConfig(), \OC::$server->getGroupManager(), \OC::$server->getNotificationManager(), \OC::$server->query(ITimeFactory::class)),
new ClearCollectionsAccessCache(\OC::$server->getConfig(), \OC::$server->query(IManager::class)),
@@ -238,7 +237,7 @@ class Repair implements IOutput {
$connectionAdapter = \OC::$server->get(ConnectionAdapter::class);
$config = \OC::$server->getConfig();
$steps = [
- new Collation(\OC::$server->getConfig(), \OC::$server->getLogger(), $connectionAdapter, true),
+ new Collation(\OC::$server->getConfig(), \OC::$server->get(LoggerInterface::class), $connectionAdapter, true),
new SqliteAutoincrement($connection),
new SaveAccountsTableData($connectionAdapter, $config),
new DropAccountTermsTable($connectionAdapter),