MOBILE-3833 course: Don't automatically change section in all sections

main
Dani Palou 2022-03-15 08:16:19 +01:00
parent 275ef0ac21
commit 66ef17eff9
1 changed files with 1 additions and 1 deletions

View File

@ -153,7 +153,7 @@ export class CoreCourseFormatComponent implements OnInit, OnChanges, OnDestroy {
if (!this.lastModuleViewed || data.timeaccess > this.lastModuleViewed.timeaccess) {
this.lastModuleViewed = data;
if (this.selectedSection) {
if (this.selectedSection && this.selectedSection.id !== this.allSectionsId) {
// Change section to display the one with the last viewed module
const lastViewedSection = this.getViewedModuleSection(this.sections, data);
if (lastViewedSection && lastViewedSection.id !== this.selectedSection?.id) {