diff --git a/erpnext/education/utils.py b/erpnext/education/utils.py index a88f66b04ce..641664c48ed 100644 --- a/erpnext/education/utils.py +++ b/erpnext/education/utils.py @@ -135,7 +135,7 @@ def check_content_completion(content_name, content_type, enrollment_name): def check_quiz_completion(quiz, enrollment_name): attempts = frappe.get_all("Quiz Activity", filters={'enrollment': enrollment_name, 'quiz': quiz.name}, fields=["name", "activity_date", "score", "status"]) - status = bool(len(attempts) == quiz.max_attempts) + status = False if quiz.max_attempts == 0 else bool(len(attempts) == quiz.max_attempts) score = None result = None if attempts: diff --git a/erpnext/public/js/education/lms/components/Quiz.vue b/erpnext/public/js/education/lms/components/Quiz.vue index c0d6537a0d7..0a6199a7568 100644 --- a/erpnext/public/js/education/lms/components/Quiz.vue +++ b/erpnext/public/js/education/lms/components/Quiz.vue @@ -10,21 +10,21 @@