Merge branch 'MDL-74756-MOODLE_401_STABLE' of https://github.com/sh-csg/moodle into MOODLE_401_STABLE

This commit is contained in:
Ilya Tregubov
2023-01-19 10:30:32 +08:00
@@ -277,13 +277,13 @@ class condition extends \core_availability\condition {
if (!isset($sectionprevious[$othercm->section])) {
$sectionprevious[$othercm->section] = $lastcmid;
}
if ($lastcmid) {
$this->modfastprevious[$othercm->id] = $lastcmid;
}
// Load previous to all cms with completion.
if ($othercm->completion == COMPLETION_TRACKING_NONE) {
continue;
}
if ($lastcmid) {
$this->modfastprevious[$othercm->id] = $lastcmid;
}
$lastcmid = $othercm->id;
}
// Fill empty sections index.