From 7565d6ff0105a8f55a6f92332c5fe3ade2cbd081 Mon Sep 17 00:00:00 2001 From: cuom1999 Date: Fri, 28 Apr 2023 11:42:03 -0500 Subject: [PATCH] Fix edit button in editorial page --- judge/views/problem.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/judge/views/problem.py b/judge/views/problem.py index cd461ea..3022f8f 100644 --- a/judge/views/problem.py +++ b/judge/views/problem.py @@ -194,7 +194,7 @@ class ProblemSolution( PageVoteDetailView, BookMarkDetailView, ): - context_object_name = "problem" + context_object_name = "solution" template_name = "problem/editorial.html" def get_title(self): @@ -220,7 +220,7 @@ class ProblemSolution( ) and not self.request.user.has_perm("judge.see_private_solution"): raise Http404() - context["solution"] = solution + context["problem"] = self.problem context["has_solved_problem"] = self.problem.id in self.get_completed_problems() return context