Skip to content

Commit d750b91

Browse files
committed
MOBILE-4362 quiz: Fix review not opened after finish offline quiz
1 parent e9601ae commit d750b91

File tree

1 file changed

+1
-2
lines changed
  • src/addons/mod/quiz/components/index

1 file changed

+1
-2
lines changed

src/addons/mod/quiz/components/index/index.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -406,6 +406,7 @@ export class AddonModQuizIndexComponent extends CoreCourseModuleMainActivityComp
406406

407407
// Verify that user can see the review.
408408
const attemptId = this.autoReview.attemptId;
409+
this.autoReview = undefined;
409410

410411
if (this.quizAccessInfo?.canreviewmyattempts) {
411412
try {
@@ -452,7 +453,6 @@ export class AddonModQuizIndexComponent extends CoreCourseModuleMainActivityComp
452453
// Check if we need to go to review an attempt automatically.
453454
if (this.autoReview && this.autoReview.synced) {
454455
promise = this.goToAutoReview();
455-
this.autoReview = undefined;
456456
}
457457

458458
// Refresh data.
@@ -594,7 +594,6 @@ export class AddonModQuizIndexComponent extends CoreCourseModuleMainActivityComp
594594
if (!this.isDestroyed && this.isCurrentView) {
595595
openReview = true;
596596
}
597-
this.autoReview = undefined;
598597
}
599598

600599
const [options] = await Promise.all([

0 commit comments

Comments
 (0)