diff --git a/dev_config/eslint.config.mjs b/dev_config/eslint.config.mjs index b5522eb..cc7db54 100644 --- a/dev_config/eslint.config.mjs +++ b/dev_config/eslint.config.mjs @@ -23,6 +23,7 @@ export default defineConfig([js.configs.recommended,{ "argsIgnorePattern": "^_", "varsIgnorePattern": "^_", "caughtErrorsIgnorePattern": "^_" - }] + }], + "prefer-const": ["error"] }, }]); \ No newline at end of file diff --git a/web/scripts/dialog.js b/web/scripts/dialog.js index 5209059..24660c5 100644 --- a/web/scripts/dialog.js +++ b/web/scripts/dialog.js @@ -113,8 +113,7 @@ class ErrorDialog extends HTMLElement { } this.dialog.addEventListener("close", () => { - if (this.dialog.returnValue === "ok") {} - else if (this.dialog.returnValue === "copy") { + if (this.dialog.returnValue === "copy") { let errors = ""; for (const error of this.errors.childNodes) { errors += `${error.innerText}\n`;