From 35908f776fe0c5769a3a860f2720e8b4347d8475 Mon Sep 17 00:00:00 2001 From: Albert Gasset Date: Wed, 5 Sep 2018 15:13:20 +0200 Subject: [PATCH] MOBILE-2567 quiz: Fix submission of overdue attempts with grace period --- src/addon/mod/quiz/components/index/addon-mod-quiz-index.html | 4 ++-- src/core/question/providers/helper.ts | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/addon/mod/quiz/components/index/addon-mod-quiz-index.html b/src/addon/mod/quiz/components/index/addon-mod-quiz-index.html index 04a3b504b..5304251e7 100644 --- a/src/addon/mod/quiz/components/index/addon-mod-quiz-index.html +++ b/src/addon/mod/quiz/components/index/addon-mod-quiz-index.html @@ -33,7 +33,7 @@ - +

{{ 'addon.mod_quiz.summaryofattempts' | translate }}

@@ -64,7 +64,7 @@
- + {{ gradeResult }} {{ 'core.course.overriddennotice' | translate }} diff --git a/src/core/question/providers/helper.ts b/src/core/question/providers/helper.ts index f1c9b5b3c..4e0f6075f 100644 --- a/src/core/question/providers/helper.ts +++ b/src/core/question/providers/helper.ts @@ -530,6 +530,7 @@ export class CoreQuestionHelperProvider { prepareAnswers(questions: any[], answers: any, offline?: boolean, siteId?: string): Promise { const promises = []; + questions = questions || []; questions.forEach((question) => { promises.push(this.questionDelegate.prepareAnswersForQuestion(question, answers, offline, siteId)); });