fix: only cleanup orphaned shared daly

Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
Robin Appelman 2024-02-15 16:51:52 +01:00 committed by Julius Härtl
parent 269bd2442a
commit 417944b388
No known key found for this signature in database
GPG key ID: 4C614C6ED2CDE6DF

View file

@ -31,20 +31,14 @@ use OCP\BackgroundJob\TimedJob;
* Delete all share entries that have no matching entries in the file cache table.
*/
class DeleteOrphanedSharesJob extends TimedJob {
/**
* Default interval in minutes
*
* @var int $defaultIntervalMin
**/
protected $defaultIntervalMin = 15;
/**
* sets the correct interval for this timed job
*/
public function __construct(ITimeFactory $time) {
parent::__construct($time);
$this->interval = $this->defaultIntervalMin * 60;
$this->setInterval(24 * 60 * 60); // 1 day
$this->setTimeSensitivity(self::TIME_INSENSITIVE);
}
/**