mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
MDL-24927 fixed orphaned activities regression when single topic selected
This commit is contained in:
parent
8dc68e3e7c
commit
36b1c872a3
2 changed files with 2 additions and 2 deletions
|
@ -255,7 +255,7 @@ while ($section <= $course->numsections) {
|
|||
$section++;
|
||||
}
|
||||
|
||||
if ($PAGE->user_is_editing() && has_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id))) {
|
||||
if (!$displaysection and $PAGE->user_is_editing() and has_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id))) {
|
||||
// print stealth sections if present
|
||||
$modinfo = get_fast_modinfo($course);
|
||||
foreach ($sections as $section=>$thissection) {
|
||||
|
|
|
@ -256,7 +256,7 @@ defined('MOODLE_INTERNAL') || die();
|
|||
$weekdate = $nextweekdate;
|
||||
}
|
||||
|
||||
if ($PAGE->user_is_editing() && has_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id))) {
|
||||
if (!$displaysection and $PAGE->user_is_editing() and has_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id))) {
|
||||
// print stealth sections if present
|
||||
$modinfo = get_fast_modinfo($course);
|
||||
foreach ($sections as $section=>$thissection) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue