Merge pull request #53421 from nextcloud/fix/convert-schedulednotifications-to-timedjob

fix: make ScheduledNotifications a TimedJob and run every minute
This commit is contained in:
Joas Schilling 2025-06-27 11:04:11 +02:00 committed by GitHub
commit 57a375ce97
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -13,10 +13,10 @@ use OCA\FilesReminders\Db\ReminderMapper;
use OCA\FilesReminders\Service\ReminderService;
use OCP\AppFramework\Db\DoesNotExistException;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\BackgroundJob\Job;
use OCP\BackgroundJob\TimedJob;
use Psr\Log\LoggerInterface;
class ScheduledNotifications extends Job {
class ScheduledNotifications extends TimedJob {
public function __construct(
ITimeFactory $time,
protected ReminderMapper $reminderMapper,
@ -24,6 +24,8 @@ class ScheduledNotifications extends Job {
protected LoggerInterface $logger,
) {
parent::__construct($time);
$this->setInterval(60);
}
/**