Don't kill tests on a NULL bench

This commit is contained in:
Andrew Grant committed 2020-06-01 22:30:30 -04:00
1 parent 4526a0425a
commit 19a8dd4172
1 file changed
+3 -2
+3 -2
View File
@@ -497,8 +497,9 @@ def clientWrongBench(request):
if machine.user != user: return HttpResponse('Bad Machine')
# Find and stop the test with the bad bench
test = Test.objects.get(id=int(request.POST['testid']))
test.finished = True; test.save()
if int(request.POST['wrong']) != 0:
test = Test.objects.get(id=int(request.POST['testid']))
test.finished = True; test.save()
# Collect information on the Error
wrong = request.POST['wrong']