diff options
Diffstat (limited to 'frontend/ui.ts')
-rw-r--r-- | frontend/ui.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/frontend/ui.ts b/frontend/ui.ts index 22f9d71..8ce34a4 100644 --- a/frontend/ui.ts +++ b/frontend/ui.ts @@ -11,6 +11,7 @@ export function add_page_content(engine?: string) { } function section_search(engine: string) { + engine = engine.toLowerCase(); const section = document.createElement("section") section.classList.add("search") @@ -55,7 +56,8 @@ function section_engine_select() { section.classList.add("engine-select") const select = async (e: string) => { - if (!(await bangs)[e]) return status("error", `Engine ${JSON.stringify(e)} does not exist.`) + const engine = e.toLowerCase(); + if (!(await bangs)[engine]) return status("error", `Engine ${JSON.stringify(e)} does not exist.`) window.location.hash = `#${e}` } |