diff --git a/OpenBench/views.py b/OpenBench/views.py index ffae7c2..c8ac849 100644 --- a/OpenBench/views.py +++ b/OpenBench/views.py @@ -349,8 +349,12 @@ def approveTest(request, id): if not profile.approver: raise Exception('No Approver Permissions on Account') - # Approve the provided test + # Ensure cross verification is used, except for the site admin test = Test.objects.get(id=id) + if test.author == profile.user.username and not profile.user.is_superuser: + raise Exception('Cross Approval is Required') + + # Approve the provided test if test.approved: return HttpResponseRedirect('/index/') test.approved = True