From bcaf554896a92f43cc2245d6f7320c6292bdd91b Mon Sep 17 00:00:00 2001 From: Dharun Ashokkumar Date: Tue, 20 Jan 2026 21:17:58 +0530 Subject: [PATCH] fix: address code review feedback Use HiddenInput for webhook URL, replace button with ToggleSection, inline webhook variable, and move script to constant to avoid duplication --- .../notification-providers/google-sheets.js | 4 +- src/components/notifications/GoogleSheets.vue | 102 +++++++----------- 2 files changed, 41 insertions(+), 65 deletions(-) diff --git a/server/notification-providers/google-sheets.js b/server/notification-providers/google-sheets.js index 8c8ec1581..fc74a6b55 100644 --- a/server/notification-providers/google-sheets.js +++ b/server/notification-providers/google-sheets.js @@ -32,8 +32,6 @@ class GoogleSheets extends NotificationProvider { } // Send data to Google Apps Script webhook - const webhookUrl = notification.googleSheetsWebhookUrl; - const config = this.getAxiosConfigWithProxy({ headers: { "Content-Type": "application/json" @@ -50,7 +48,7 @@ class GoogleSheets extends NotificationProvider { statusCode }; - await axios.post(webhookUrl, data, config); + await axios.post(notification.googleSheetsWebhookUrl, data, config); return okMsg; } catch (error) { diff --git a/src/components/notifications/GoogleSheets.vue b/src/components/notifications/GoogleSheets.vue index 2f167b3ce..f702a94b4 100644 --- a/src/components/notifications/GoogleSheets.vue +++ b/src/components/notifications/GoogleSheets.vue @@ -1,13 +1,12 @@