mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
"MDL-19118, replace course it with course object to improve performance"
This commit is contained in:
parent
5758852313
commit
80555111bc
@ -24,7 +24,7 @@ require_once($CFG->dirroot . '/comment/lib.php');
|
||||
$contextid = optional_param('contextid', SYSCONTEXTID, PARAM_INT);
|
||||
list($context, $course, $cm) = get_context_info_array($contextid);
|
||||
|
||||
require_login($course->id, true, $cm);
|
||||
require_login($course, true, $cm);
|
||||
|
||||
$err = new stdclass;
|
||||
|
||||
|
@ -30,7 +30,7 @@ if ($context->contextlevel == CONTEXT_MODULE) {
|
||||
} else {
|
||||
$cm = null;
|
||||
}
|
||||
require_login($course->id, true, $cm);
|
||||
require_login($course, true, $cm);
|
||||
|
||||
$err = new stdclass;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user