mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-31186 fix wrong context preloading sql
This commit is contained in:
parent
f6b4ec2b4a
commit
ecfc06d88a
@ -518,7 +518,7 @@ class core_user_external extends external_api {
|
||||
$courses = array();
|
||||
list($cselect, $cjoin) = context_instance_preload_sql('c.id', CONTEXT_COURSE, 'ctx');
|
||||
list($sqlcourseids, $params) = $DB->get_in_or_equal(array_unique($courseids));
|
||||
$coursesql = "SELECT c.* $uselect
|
||||
$coursesql = "SELECT c.* $cselect
|
||||
FROM {course} c $cjoin
|
||||
WHERE c.id $sqlcourseids";
|
||||
$rs = $DB->get_recordset_sql($coursesql, $params);
|
||||
|
Loading…
x
Reference in New Issue
Block a user