MOBILE-2722 sitehome: Reset blocks list when not suported
parent
abddc4766d
commit
84d6ea5118
|
@ -158,6 +158,7 @@ export class CoreSiteHomeIndexComponent implements OnInit {
|
||||||
if (canGetBlocks) {
|
if (canGetBlocks) {
|
||||||
this.domUtils.showErrorModal(error);
|
this.domUtils.showErrorModal(error);
|
||||||
}
|
}
|
||||||
|
this.blocks = [];
|
||||||
|
|
||||||
// Cannot get the blocks, just show site main menu if needed.
|
// Cannot get the blocks, just show site main menu if needed.
|
||||||
if (sections[0] && this.courseHelper.sectionHasContent(sections[0])) {
|
if (sections[0] && this.courseHelper.sectionHasContent(sections[0])) {
|
||||||
|
@ -166,7 +167,6 @@ export class CoreSiteHomeIndexComponent implements OnInit {
|
||||||
});
|
});
|
||||||
this.hasSupportedBlock = true;
|
this.hasSupportedBlock = true;
|
||||||
} else {
|
} else {
|
||||||
this.blocks = [];
|
|
||||||
this.hasSupportedBlock = false;
|
this.hasSupportedBlock = false;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue