From 8652473212973147657a8ead91038179d07542bb Mon Sep 17 00:00:00 2001 From: Gareth Barnard <1058419+gjb2048@users.noreply.github.com> Date: Thu, 4 Apr 2024 12:46:09 +0100 Subject: [PATCH] Return to course page after saving section - M4.4. --- lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib.php b/lib.php index 299e7c55..318b6f86 100755 --- a/lib.php +++ b/lib.php @@ -334,7 +334,7 @@ public function get_view_url($section, $options = []) { } else { $sectionno = $section; } - if ((!empty($options['navigation']) || array_key_exists('sr', $options)) && $sectionno !== null) { + if (!empty($options['navigation']) && $sectionno !== null) { // Display section on separate page. $sectioninfo = $this->get_section($sectionno); return new moodle_url('/course/section.php', ['id' => $sectioninfo->id]);