From b105603fd1133c9d64d712c6c97139ff78f6503d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=B4me=20Chilliet?= Date: Tue, 6 Feb 2024 14:04:39 +0100 Subject: [PATCH] chore: Remove last uses of IJob::execute method MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Côme Chilliet --- apps/federation/tests/BackgroundJob/GetSharedSecretTest.php | 2 +- cron.php | 4 ++-- tests/lib/Command/CronBusTest.php | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php b/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php index c0316b8247f..55db5cb744f 100644 --- a/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php +++ b/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php @@ -155,7 +155,7 @@ class GetSharedSecretTest extends TestCase { $this->jobList->expects($this->never())->method('add'); } - $getSharedSecret->execute($this->jobList); + $getSharedSecret->start($this->jobList); } public function dataTestExecute() { diff --git a/cron.php b/cron.php index 9a3b6297d80..e24219bb790 100644 --- a/cron.php +++ b/cron.php @@ -154,7 +154,7 @@ try { $memoryBefore = memory_get_usage(); $memoryPeakBefore = memory_get_peak_usage(); - $job->execute($jobList, $logger); + $job->start($jobList); $memoryAfter = memory_get_usage(); $memoryPeakAfter = memory_get_peak_usage(); @@ -189,7 +189,7 @@ try { $job = $jobList->getNext(); if ($job != null) { $logger->debug('WebCron call has selected job with ID ' . strval($job->getId()), ['app' => 'cron']); - $job->execute($jobList, $logger); + $job->start($jobList); $jobList->setLastJob($job); } OC_JSON::success(); diff --git a/tests/lib/Command/CronBusTest.php b/tests/lib/Command/CronBusTest.php index ea610a135d8..4b3c7dca95a 100644 --- a/tests/lib/Command/CronBusTest.php +++ b/tests/lib/Command/CronBusTest.php @@ -44,7 +44,7 @@ class CronBusTest extends AsyncBusTest { protected function runJobs() { $jobs = $this->jobList->getAll(); foreach ($jobs as $job) { - $job->execute($this->jobList); + $job->start($this->jobList); } } }