]> git.mjollnir.org Git - moodle.git/commitdiff
FIx the header too by requiring login to the course
authormoodler <moodler>
Sun, 1 Oct 2006 09:31:49 +0000 (09:31 +0000)
committermoodler <moodler>
Sun, 1 Oct 2006 09:31:49 +0000 (09:31 +0000)
course/editsection.php

index 06689c844941871ee4610f257583ce7f7a530675..9fc50e4b759a7e977b43d7d91e5432d9c4812656 100644 (file)
@@ -6,8 +6,6 @@
 
     $id = required_param('id',PARAM_INT);    // Week ID
 
-    require_login();
-
     if (! $section = get_record("course_sections", "id", $id)) {
         error("Course section is incorrect");
     }
@@ -16,6 +14,8 @@
         error("Could not find the course!");
     }
 
+    require_login($course->id);
+
     require_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id));
 
 /// If data submitted, then process and store.