From 8c3e89887c2440b2c31436e97bd23f538518fb6b Mon Sep 17 00:00:00 2001 From: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com> Date: Tue, 21 Jul 2026 19:50:43 +0000 Subject: [PATCH 1/3] =?UTF-8?q?feat:=20implement=20issue=20#428=20?= =?UTF-8?q?=E2=80=94=20SonarCloud:=20JavaScript/TypeScript=20code=20qualit?= =?UTF-8?q?y?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- deploy/index.html | 47 ++++++++++--------- deploy/tests/ui.spec.js | 8 +++- gas-installer/Index.html | 8 ++-- gas-installer/src/index.js | 7 ++- scripts/check-coverage.js | 8 ++-- src/calendar-to-briefing-doc/src/index.js | 10 ++-- .../tests/index.test.js | 37 +++++---------- src/calendar-to-sheets/src/index.js | 9 ++-- src/deploy/index.js | 2 +- src/gas-utils.js | 16 +++---- src/gmail-to-drive-by-labels/src/index.js | 14 +++--- .../tests/code.test.js | 16 +++++-- .../tests/gas-utils.test.js | 11 +++++ test-utils/mocks.js | 6 +-- test-utils/setup.js | 2 +- 15 files changed, 104 insertions(+), 97 deletions(-) diff --git a/deploy/index.html b/deploy/index.html index 1fac2f82..2703d3f2 100644 --- a/deploy/index.html +++ b/deploy/index.html @@ -651,7 +651,6 @@

3Configure your scripts

} catch { // best-effort; ignore storage errors } - const safeId = escapeHtml(scriptId) const section = document.getElementById('setup-section-' + scriptId) if (section) { section.innerHTML = `
⏱ Trigger previously activated.
` @@ -667,7 +666,7 @@

3Configure your scripts

* to activate the hourly trigger. */ function buildSetupSource(triggerFn) { - if (!/^[a-zA-Z_][a-zA-Z0-9_]*$/.test(triggerFn)) { + if (!/^[a-zA-Z_]\w*$/.test(triggerFn)) { throw new Error( 'Invalid trigger function name: ' + JSON.stringify(triggerFn) ) @@ -1189,14 +1188,11 @@

3Configure your scripts

'' + '