2022-09-19 13:03:27 -04:00
|
|
|
<?php
|
2025-06-30 09:04:05 -04:00
|
|
|
|
2026-02-09 04:53:58 -05:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
2022-09-19 13:03:27 -04:00
|
|
|
/**
|
2024-05-23 03:26:56 -04:00
|
|
|
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
2022-09-19 13:03:27 -04:00
|
|
|
*/
|
|
|
|
|
namespace OC\Repair;
|
|
|
|
|
|
|
|
|
|
use OC\Avatar\AvatarManager;
|
|
|
|
|
use OCP\AppFramework\Utility\ITimeFactory;
|
|
|
|
|
use OCP\BackgroundJob\QueuedJob;
|
|
|
|
|
|
|
|
|
|
class ClearGeneratedAvatarCacheJob extends QueuedJob {
|
2025-11-17 09:32:54 -05:00
|
|
|
public function __construct(
|
|
|
|
|
ITimeFactory $timeFactory,
|
|
|
|
|
protected AvatarManager $avatarManager,
|
|
|
|
|
) {
|
2022-09-19 13:03:27 -04:00
|
|
|
parent::__construct($timeFactory);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public function run($argument) {
|
|
|
|
|
$this->avatarManager->clearCachedAvatars();
|
|
|
|
|
}
|
|
|
|
|
}
|