diff --git a/lib/form/format.php b/lib/form/format.php index 7fad587b2d2..c2b3e0e8daa 100644 --- a/lib/form/format.php +++ b/lib/form/format.php @@ -65,7 +65,8 @@ class MoodleQuickForm_format extends MoodleQuickForm_select{ { switch ($event) { case 'createElement': - $this->load(format_text_menu()); + $menu = format_text_menu(); + $this->load($menu); $this->setHelpButton(array('textformat', get_string('helpformatting'))); break; case 'updateValue' :