MOBILE-3946 completion: Fix bug detecting automatic completion
parent
09a8d8fead
commit
007fbe0ab2
|
@ -362,11 +362,11 @@ export class AddonModH5PActivityIndexComponent extends CoreCourseModuleMainActiv
|
|||
/**
|
||||
* Play the package.
|
||||
*/
|
||||
play(): void {
|
||||
async play(): Promise<void> {
|
||||
this.playing = true;
|
||||
|
||||
// Mark the activity as viewed.
|
||||
AddonModH5PActivity.logView(this.h5pActivity!.id, this.h5pActivity!.name, this.siteId);
|
||||
await AddonModH5PActivity.logView(this.h5pActivity!.id, this.h5pActivity!.name, this.siteId);
|
||||
|
||||
CoreCourse.checkModuleCompletion(this.courseId, this.module.completiondata);
|
||||
}
|
||||
|
|
|
@ -203,11 +203,7 @@ export class CoreCourseModuleMainActivityComponent extends CoreCourseModuleMainR
|
|||
|
||||
try {
|
||||
if (refresh && this.showCompletion) {
|
||||
try {
|
||||
this.module = await CoreCourse.getModule(this.module.id, this.courseId);
|
||||
} catch {
|
||||
// Ignore errors.
|
||||
}
|
||||
await CoreUtils.ignoreErrors(this.fetchModule());
|
||||
}
|
||||
|
||||
await this.fetchContent(refresh, sync, showErrors);
|
||||
|
|
Loading…
Reference in New Issue