From a0f6a6545b59b1061e96e7d17d8ec6d6f32e615e Mon Sep 17 00:00:00 2001 From: Côme Chilliet Date: Mon, 5 Dec 2022 10:13:34 +0100 Subject: Use TimedJob from OCP instead of OC MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Côme Chilliet --- apps/files_sharing/lib/DeleteOrphanedSharesJob.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'apps/files_sharing/lib/DeleteOrphanedSharesJob.php') diff --git a/apps/files_sharing/lib/DeleteOrphanedSharesJob.php b/apps/files_sharing/lib/DeleteOrphanedSharesJob.php index 6a641734680..d2cc39ff060 100644 --- a/apps/files_sharing/lib/DeleteOrphanedSharesJob.php +++ b/apps/files_sharing/lib/DeleteOrphanedSharesJob.php @@ -24,13 +24,13 @@ */ namespace OCA\Files_Sharing; -use OC\BackgroundJob\TimedJob; +use OCP\AppFramework\Utility\ITimeFactory; +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 * @@ -41,7 +41,9 @@ class DeleteOrphanedSharesJob extends TimedJob { /** * sets the correct interval for this timed job */ - public function __construct() { + public function __construct(ITimeFactory $time) { + parent::__construct($time); + $this->interval = $this->defaultIntervalMin * 60; } -- cgit v1.2.3