diff --git a/events.js b/events.js index 885e4a6..c23c7e7 100644 --- a/events.js +++ b/events.js @@ -119,15 +119,6 @@ id("search").addEventListener("input", function() { createHTMLElement("a", {"href": "?q=" + encodeURIComponent(getConflictRegex(q)) + "®ex=tight"}, ["↑ find potential gismu conflicts?"]) ])); } - if (/^[CV*?(|)a-pr-vx-z' ]+$/.test(q)) { - try { - _ = new RegExp( - `^${h(q).replace(/C/g, "[bcdfgjklmnprstvxz]").replace(/V/g, "[aeiou]").replace(/\?/g, ".").replace(/\*+/g, ".*")}$`, "i" - ); - } catch (e) { - id("info").append(createHTMLElement("p", null, ["invalid glob"])); - } - } } else if (config["regex"]) { // bad regex try { diff --git a/worker.js b/worker.js index 0691dbe..de4ebfa 100644 --- a/worker.js +++ b/worker.js @@ -55,21 +55,6 @@ function search(query) { results.push([entry, 1]); } } - } else if (/^[CV*?(|)a-pr-vx-z' ]+$/.test(original)) { - // also stolen from lynn of lidysisku etc fame - var rgx; - try { - rgx = new RegExp( - `^${h(original).replace(/C/g, "[bcdfgjklmnprstvxz]").replace(/V/g, "[aeiou]").replace(/\?/g, ".").replace(/\*+/g, ".*")}$`, "i" - ); - } catch { - return []; - } - for (const entry of jbo) { - if (rgx.test(entry.word)) { - results.push([entry, 9]); - } - } } else if (/^[A-GI-PR-VX-Z][A-GhI-PR-VX-Zabc0-9*]*$/.test(original)) { // TODO: make this work (issue #1) } else {