From bb78b743dd354a04148c69805187dec75aae2ea4 Mon Sep 17 00:00:00 2001 From: cuom1999 Date: Wed, 4 Jan 2023 15:57:10 -0600 Subject: [PATCH] Fix bug --- judge/views/submission.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/judge/views/submission.py b/judge/views/submission.py index 2912bed..8ae921b 100644 --- a/judge/views/submission.py +++ b/judge/views/submission.py @@ -160,7 +160,7 @@ class SubmissionSource(SubmissionDetailBase): def get_hidden_subtasks(request, submission): contest = submission.contest_object - if contest.is_editable_by(request.user): + if contest and contest.is_editable_by(request.user): return set() if contest and contest.format.has_hidden_subtasks: try: