MOBILE-3833 label: Fix error when downloading course with label

main
Dani Palou 2022-01-24 15:14:16 +01:00
parent 5a2016cb67
commit fe55a8a59f
1 changed files with 8 additions and 0 deletions

View File

@ -63,5 +63,13 @@ export class AddonModLabelPrefetchHandlerService extends CoreCourseResourcePrefe
await CoreUtils.allPromises(promises);
}
/**
* @inheritdoc
*/
async loadContents(module: CoreCourseAnyModuleData): Promise<void> {
// Labels don't have contents.
module.contents = [];
}
}
export const AddonModLabelPrefetchHandler = makeSingleton(AddonModLabelPrefetchHandlerService);