Skip to content

Commit 9db2edc

Browse files
committed
Only get freezedata on found contests
We can't do a normal $contest==null check as that might leak information if someone doesn't have access.
1 parent c7d2b0a commit 9db2edc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

webapp/src/Controller/API/ContestController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ public function problemsetAction(Request $request, string $cid): Response
364364

365365
$hasAccess = $this->dj->checkrole('jury') ||
366366
$this->dj->checkrole('api_reader') ||
367-
$contest->getFreezeData()->started();
367+
$contest?->getFreezeData()->started();
368368

369369
if (!$hasAccess) {
370370
throw new AccessDeniedHttpException();

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy