Skip to content

Commit e8ddc5e

Browse files
committed
Don't display number of balloons when no contest is active
This fixes: https://domjudge.sentry.io/issues/5634564396/?project=6376669&query=is%3Aunresolved+issue.priority%3A%5Bhigh%2C+medium%5D&referrer=issue-stream&statsPeriod=14d&stream_index=1 On the main balloonpage we don't display those balloons so it makes sense to also not update the counter in the menu.
1 parent 4a890c5 commit e8ddc5e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

webapp/src/Service/DOMJudgeService.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ public function getUpdates(): array
419419
}
420420
}
421421

422-
if ($this->checkrole('balloon')) {
422+
if ($this->checkrole('balloon') && $contest) {
423423
$balloonsQuery = $this->em->createQueryBuilder()
424424
->select('b.balloonid', 't.name', 't.location', 'p.name AS pname')
425425
->from(Balloon::class, 'b')

0 commit comments

Comments
 (0)