Merge branch 'MDL-33441-22' of git://github.com/danpoltawski/moodle into MOODLE_22_STABLE

This commit is contained in:
Sam Hemelryk
2012-06-06 10:09:54 +12:00
+5
View File
@@ -2091,6 +2091,11 @@ function get_course_category_tree($id = 0, $depth = 0) {
return array($categories, $categoryids);
}
if (empty($categoryids)) {
// No categories available (probably all hidden).
return array();
}
// The depth is 0 this function has just been called so we can finish it off
list($ccselect, $ccjoin) = context_instance_preload_sql('c.id', CONTEXT_COURSE, 'ctx');