feat(bg-jobs): Allow calling cron.php with a background job class

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2021-12-21 08:57:53 +01:00
committed by Julien Veyssier
parent 8694675a26
commit 52eb6d8726
3 changed files with 10 additions and 5 deletions
+2 -1
View File
@@ -160,7 +160,8 @@ try {
$endTime = time() + 14 * 60;
$executedJobs = [];
while ($job = $jobList->getNext($onlyTimeSensitive)) {
$jobClass = isset($argv[1]) ? $argv[1] : null;
while ($job = $jobList->getNext($onlyTimeSensitive, $jobClass)) {
if (isset($executedJobs[$job->getId()])) {
$jobList->unlockJob($job);
break;