]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-14741 - Prevent a notice occuring before configuration is done, and cleanup a...
authorscyrma <scyrma>
Mon, 9 Jun 2008 08:22:20 +0000 (08:22 +0000)
committerscyrma <scyrma>
Mon, 9 Jun 2008 08:22:20 +0000 (08:22 +0000)
lib/editor/htmlEditor.class.php

index 588fa7d3b1ee10844cfda61040b6b544d2b56469..40a6709d34e535de35901684a89e64e616035bd4 100644 (file)
@@ -19,38 +19,9 @@ class htmlEditor {
         global $CFG;\r
 \r
         if ($editor == '') {\r
-            $editor = $CFG->defaulthtmleditor;\r
+            $editor = (isset($CFG->defaulthtmleditor) ? $CFG->defaulthtmleditor : '');\r
         }\r
 \r
-/*\r
-        if ($editor == '') {\r
-            switch ($CFG->htmleditorselection) {\r
-                case '0':\r
-                    return '';\r
-                    break;\r
-\r
-                case '1':\r
-                    $editor = 'tinymce';\r
-                    break;\r
-\r
-                case '2':\r
-                    $editor = 'fckeditor';\r
-                    break;\r
-\r
-                case '3':\r
-                    $editor = 'xinha';\r
-                    break;\r
-\r
-                case '4':\r
-                    $editor = 'yuirte';\r
-                    break;\r
-\r
-                default:\r
-                    return '';\r
-                    break;\r
-            }\r
-        }\r
-*/\r
         $configuration = '';\r
 \r
         switch ($editor) {\r