]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Remove obsolete code
authormoisseev <moiseev@mezonplus.ru>
Tue, 14 Nov 2023 07:58:04 +0000 (10:58 +0300)
committermoisseev <moiseev@mezonplus.ru>
Tue, 14 Nov 2023 07:58:04 +0000 (10:58 +0300)
ES6 is required now for WebUI anyway.

interface/js/app/config.js

index b3f4e566190410fdb7d5b9511f1f2ea97d6ee63e..71a59a34be2fbb31ce961d294b4d7163de15473d 100644 (file)
@@ -159,15 +159,6 @@ define(["jquery", "codejar", "linenumbers", "prism"],
             };
             let mode = "advanced";
 
-            // CodeJar requires ES6
-            if (!window.CodeJar ||
-                // Required to restore cursor position
-                (typeof window.getSelection().setBaseAndExtent !== "function")) {
-                mode = "basic";
-                $("input[name=editorMode][value='basic']").closest(".btn").button("toggle");
-                $("input[name=editorMode][value='advanced']").closest(".btn").addClass("disabled").prop("title", "Not supported by web browser");
-            }
-
             // Modal form for maps
             $(document).on("click", "[data-bs-toggle=\"modal\"]", function () {
                 var checked_server = rspamd.getSelector("selSrv");