MDL-37085 Substitute function print_section_add_menus() with core_course_renderer...
[moodle.git] / blocks / site_main_menu / block_site_main_menu.php
index 03a5d4c..4cd681f 100644 (file)
@@ -134,7 +134,9 @@ class block_site_main_menu extends block_list {
             $this->content->icons[] = '';
         }
 
-        $this->content->footer = print_section_add_menus($course, 0, null, true, true);
+        $courserenderer = $this->page->get_renderer('core', 'course');
+        $this->content->footer = $courserenderer->course_section_add_cm_control($course,
+                0, null, array('inblock' => true));
 
         return $this->content;
     }