]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix(cron): Reset the reserved_at when force executing from CLI 42389/head
authorJoas Schilling <coding@schilljs.com>
Wed, 20 Dec 2023 09:07:41 +0000 (10:07 +0100)
committerJoas Schilling <coding@schilljs.com>
Wed, 20 Dec 2023 09:07:41 +0000 (10:07 +0100)
Signed-off-by: Joas Schilling <coding@schilljs.com>
lib/private/BackgroundJob/JobList.php

index 3ec2e0af1b3f09c6fef620bb5c94678be4c64047..93d5cf74a20f7f5225260cd44765a82e20bfb4b1 100644 (file)
@@ -392,6 +392,7 @@ class JobList implements IJobList {
                $query = $this->connection->getQueryBuilder();
                $query->update('jobs')
                        ->set('execution_duration', $query->createNamedParameter($timeTaken, IQueryBuilder::PARAM_INT))
+                       ->set('reserved_at', $query->createNamedParameter(0, IQueryBuilder::PARAM_INT))
                        ->where($query->expr()->eq('id', $query->createNamedParameter($job->getId(), IQueryBuilder::PARAM_INT)));
                $query->executeStatement();
        }