Skip to content

Commit e2d8229

Browse files
committed
fix: author not integer
1 parent 66a650c commit e2d8229

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

submission/views.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,9 @@ def get_queryset(self):
8787
'status_memory')
8888
if not is_admin_or_root(self.request.user):
8989
queryset = queryset.filter(contest__isnull=True, problem__visible=True)
90-
if author:
90+
if author and author.isdigit():
9191
queryset = queryset.filter(author_id=author)
92-
if prob:
92+
if prob and prob.isdigit():
9393
queryset = queryset.filter(problem_id=prob)
9494
if kw:
9595
q = Q(author__username__iexact=kw)

0 commit comments

Comments
 (0)