From 4996b40860a531a39a8cd7d16b3c05600ab4b014 Mon Sep 17 00:00:00 2001 From: Christie Rice <8483753+crice100@users.noreply.github.com> Date: Mon, 2 Aug 2021 13:07:52 -0400 Subject: [PATCH] fix: Add check for existence of grade (#28348) MICROBA-678 --- common/djangoapps/student/helpers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/djangoapps/student/helpers.py b/common/djangoapps/student/helpers.py index 4c8a723b08..372187b10c 100644 --- a/common/djangoapps/student/helpers.py +++ b/common/djangoapps/student/helpers.py @@ -600,7 +600,7 @@ def _cert_info(user, enrollment, cert_status): if ( status_dict['status'] != CertificateStatuses.downloadable and (cert_generation_enabled(course_overview.id) or auto_certificate_generation_enabled()) and - persisted_grade.passed + persisted_grade and persisted_grade.passed ): status_dict['status'] = CertificateStatuses.requesting