From cad01701673540c388e5ec9eac8e6957d9ecef95 Mon Sep 17 00:00:00 2001 From: Ross Date: Mon, 2 Aug 2021 12:01:55 +0100 Subject: [PATCH] . --- longs/views.py | 8 ++++---- physics/views.py | 8 ++++---- rapids/views.py | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/longs/views.py b/longs/views.py index d9232cba..c4b060ef 100755 --- a/longs/views.py +++ b/longs/views.py @@ -582,10 +582,10 @@ def loadJsonAnswer(answer): exam = get_object_or_404(Exam, pk=eid) - if not exam.active: - return False, JsonResponse( - {"success": False, "error": "No active exam: {}".format(eid)} - ) + #if not exam.active: + # return False, JsonResponse( + # {"success": False, "error": "No active exam: {}".format(eid)} + # ) exiting_answers = CidUserAnswer.objects.filter( question__id=answer["qid"], exam__id=eid, cid=answer["cid"] diff --git a/physics/views.py b/physics/views.py index 3162c615..90001f2e 100644 --- a/physics/views.py +++ b/physics/views.py @@ -254,10 +254,10 @@ def loadJsonAnswer(answer): exam = get_object_or_404(Exam, pk=answer["eid"]) - if not exam.active: - return False, JsonResponse( - {"success": False, "error": "No active exam: {}".format(answer["eid"])} - ) + #if not exam.active: + # return False, JsonResponse( + # {"success": False, "error": "No active exam: {}".format(answer["eid"])} + # ) questions = defaultdict(dict) diff --git a/rapids/views.py b/rapids/views.py index b5560cee..7587a5b8 100755 --- a/rapids/views.py +++ b/rapids/views.py @@ -591,10 +591,10 @@ def loadJsonAnswer(answer): exam = get_object_or_404(Exam, pk=eid) - if not exam.active: - return False, JsonResponse( - {"success": False, "error": "No active exam: {}".format(eid)} - ) + #if not exam.active: + # return False, JsonResponse( + # {"success": False, "error": "No active exam: {}".format(eid)} + # ) exiting_answers = CidUserAnswer.objects.filter( question__id=answer["qid"], exam__id=eid, cid=answer["cid"]