mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 08:22:07 +02:00
MDL-53788 mod_lti: fix aggressive course cache rebuilding
This commit is contained in:
parent
a0a63678a9
commit
99a5377bb7
@ -1522,7 +1522,15 @@ function lti_update_type($type, $config) {
|
||||
}
|
||||
require_once($CFG->libdir.'/modinfolib.php');
|
||||
if ($clearcache) {
|
||||
rebuild_course_cache();
|
||||
$sql = "SELECT DISTINCT course
|
||||
FROM {lti}
|
||||
WHERE typeid = ?";
|
||||
|
||||
$courses = $DB->get_fieldset_sql($sql, array($type->id));
|
||||
|
||||
foreach ($courses as $courseid) {
|
||||
rebuild_course_cache($courseid, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user