Skip to content
This repository was archived by the owner on Jun 30, 2024. It is now read-only.

Commit 76ee4af

Browse files
committed
remove obsolete endpoint
1 parent ee67613 commit 76ee4af

File tree

1 file changed

+0
-28
lines changed

1 file changed

+0
-28
lines changed

controllers/ajax.py

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1358,34 +1358,6 @@ def getAssessResults():
13581358
)
13591359

13601360

1361-
def checkTimedReset():
1362-
# Deprecated -- Should be removed in 2020
1363-
if auth.user:
1364-
user = auth.user.username
1365-
else:
1366-
return json.dumps({"canReset": False})
1367-
1368-
divId = request.vars.div_id
1369-
course = request.vars.course
1370-
rows = (
1371-
db(
1372-
(db.timed_exam.div_id == divId)
1373-
& (db.timed_exam.sid == user)
1374-
& (db.timed_exam.course_name == course)
1375-
)
1376-
.select(orderby=~db.timed_exam.id)
1377-
.first()
1378-
)
1379-
# TODO: check the logic here if its already been reset it shouldn't be again?
1380-
if rows: # If there was a scored exam
1381-
if rows.reset == True: # noqa: E712
1382-
return json.dumps({"canReset": True})
1383-
else:
1384-
return json.dumps({"canReset": False})
1385-
else:
1386-
return json.dumps({"canReset": True})
1387-
1388-
13891361
def tookTimedAssessment():
13901362
if auth.user:
13911363
sid = auth.user.username

0 commit comments

Comments
 (0)