diff --git a/webapp/src/Controller/API/JudgehostController.php b/webapp/src/Controller/API/JudgehostController.php index 0b197c00bd..05e4df2e94 100644 --- a/webapp/src/Controller/API/JudgehostController.php +++ b/webapp/src/Controller/API/JudgehostController.php @@ -1001,11 +1001,13 @@ private function addSingleJudgingRun( break; } } + $sendJudgingEvent = false; if (!$hasNullResults || $lazyEval != DOMJudgeService::EVAL_FULL) { // NOTE: setting endtime here determines in testcases_GET // whether a next testcase will be handed out. $judging->setEndtime(Utils::now()); $this->maybeUpdateActiveJudging($judging); + $sendJudgingEvent = true; } $this->em->flush(); @@ -1062,7 +1064,7 @@ private function addSingleJudgingRun( } // Send an event for an endtime (and max runtime update). - if ($judging->getValid()) { + if ($sendJudgingEvent) { $this->eventLogService->log('judging', $judging->getJudgingid(), EventLogService::ACTION_UPDATE, $judging->getContest()->getCid()); }