mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
FIx the header too by requiring login to the course
This commit is contained in:
parent
1a5a5b0e04
commit
2fdcf5e360
1 changed files with 2 additions and 2 deletions
|
@ -6,8 +6,6 @@
|
||||||
|
|
||||||
$id = required_param('id',PARAM_INT); // Week ID
|
$id = required_param('id',PARAM_INT); // Week ID
|
||||||
|
|
||||||
require_login();
|
|
||||||
|
|
||||||
if (! $section = get_record("course_sections", "id", $id)) {
|
if (! $section = get_record("course_sections", "id", $id)) {
|
||||||
error("Course section is incorrect");
|
error("Course section is incorrect");
|
||||||
}
|
}
|
||||||
|
@ -16,6 +14,8 @@
|
||||||
error("Could not find the course!");
|
error("Could not find the course!");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
require_login($course->id);
|
||||||
|
|
||||||
require_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id));
|
require_capability('moodle/course:update', get_context_instance(CONTEXT_COURSE, $course->id));
|
||||||
|
|
||||||
/// If data submitted, then process and store.
|
/// If data submitted, then process and store.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue