aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/Repair/NC32/AddFileCacheGcBackgroundJob.php
blob: b6b0af1bf32a0c3e562006b097b0f29d3efaa837 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php

declare(strict_types=1);

/**
 * SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
 * SPDX-License-Identifier: AGPL-3.0-or-later
 */
namespace OC\Repair\NC32;

use OC\Core\BackgroundJobs\FileCacheGcJob;
use OCP\BackgroundJob\IJobList;
use OCP\Migration\IOutput;
use OCP\Migration\IRepairStep;

class AddFileCacheGcBackgroundJob implements IRepairStep {
	public function __construct(
		private readonly IJobList $jobList,
	) {
	}

	public function getName(): string {
		return 'Add background job to cleanup file cache';
	}

	public function run(IOutput $output) {
		$this->jobList->add(FileCacheGcJob::class);
	}
}