Merge branch 'master_check_cached_empty_modnames' of https://github.com/opitz/moodle
This commit is contained in:
+1
-1
@@ -400,7 +400,7 @@ function course_integrity_check($courseid, $rawmods = null, $sections = null, $f
|
||||
function get_module_types_names($plural = false, $resetcache = false) {
|
||||
static $modnames = null;
|
||||
global $DB, $CFG;
|
||||
if ($modnames === null || $resetcache) {
|
||||
if ($modnames === null || empty($modnames[0]) || $resetcache) {
|
||||
$modnames = array(0 => array(), 1 => array());
|
||||
if ($allmods = $DB->get_records("modules")) {
|
||||
foreach ($allmods as $mod) {
|
||||
|
||||
Reference in New Issue
Block a user