Skip to content

Commit

Permalink
fix submission visibility in contests
Browse files Browse the repository at this point in the history
After #1843, because of a misplaced bracket, users can't see submissions 
from contests with visible scoreboards.
  • Loading branch information
Riolku committed Feb 22, 2022
1 parent 2c9227f commit d0c959d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions judge/views/submission.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,10 +251,10 @@ def _get_queryset(self):
contest_queryset = Contest.objects.filter(Q(authors=self.request.profile) |
Q(curators=self.request.profile) |
Q(scoreboard_visibility=Contest.SCOREBOARD_VISIBLE) |
Q(end_time__lt=timezone.now()), scoreboard_visibility__in=(
Contest.SCOREBOARD_AFTER_PARTICIPATION,
Contest.SCOREBOARD_AFTER_CONTEST,
)) \
Q(end_time__lt=timezone.now(), scoreboard_visibility__in=(
Contest.SCOREBOARD_AFTER_PARTICIPATION,
Contest.SCOREBOARD_AFTER_CONTEST,
))) \
.distinct()
queryset = queryset.filter(Q(user=self.request.profile) |
Q(contest_object__in=contest_queryset) |
Expand Down

0 comments on commit d0c959d

Please sign in to comment.