Commit ecb5d308 by Braden MacDonald

Fix: Can't retry if max_attempts set to zero after answering while it was nonzero

parent 5d42eda7
......@@ -56,10 +56,9 @@ function MentoringAssessmentView(runtime, element, mentoring) {
tryAgainDOM.show();
var attempts_data = $('.attempts', element).data();
if (attempts_data.num_attempts >= attempts_data.max_attempts) {
if (attempts_data.max_attempts > 0 && attempts_data.num_attempts >= attempts_data.max_attempts) {
tryAgainDOM.attr("disabled", "disabled");
}
else {
} else {
tryAgainDOM.removeAttr("disabled");
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment