MDL-18523 fixed notice when no cms present yet

This commit is contained in:
skodak
2009-04-30 19:04:51 +00:00
parent 03c4782e11
commit b1f45df9be
+3 -1
View File
@@ -1164,7 +1164,9 @@ function grade_update_mod_grades($modinstance, $userid=0) {
function grade_get_legacy_modules($courseid) {
global $CFG;
$mods = get_course_mods($courseid);
if (!$mods = get_course_mods($courseid)) {
return array();
}
$legacy = array();
foreach ($mods as $mod) {