From: scyrma Date: Mon, 9 Jun 2008 08:22:20 +0000 (+0000) Subject: MDL-14741 - Prevent a notice occuring before configuration is done, and cleanup a... X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=723acb56932252895528a7c5b2d816ed066abde2;p=moodle.git MDL-14741 - Prevent a notice occuring before configuration is done, and cleanup a bit of code --- diff --git a/lib/editor/htmlEditor.class.php b/lib/editor/htmlEditor.class.php index 588fa7d3b1..40a6709d34 100644 --- a/lib/editor/htmlEditor.class.php +++ b/lib/editor/htmlEditor.class.php @@ -19,38 +19,9 @@ class htmlEditor { global $CFG; if ($editor == '') { - $editor = $CFG->defaulthtmleditor; + $editor = (isset($CFG->defaulthtmleditor) ? $CFG->defaulthtmleditor : ''); } -/* - if ($editor == '') { - switch ($CFG->htmleditorselection) { - case '0': - return ''; - break; - - case '1': - $editor = 'tinymce'; - break; - - case '2': - $editor = 'fckeditor'; - break; - - case '3': - $editor = 'xinha'; - break; - - case '4': - $editor = 'yuirte'; - break; - - default: - return ''; - break; - } - } -*/ $configuration = ''; switch ($editor) {