From 40ca3e405efd17f5e7f087420f61f2bcf3155350 Mon Sep 17 00:00:00 2001 From: Flook Peter Date: Fri, 22 Mar 2024 16:05:23 +0800 Subject: [PATCH] Don't save connection details if field value is empty --- app/src/main/resources/ui/connection/connection.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/main/resources/ui/connection/connection.js b/app/src/main/resources/ui/connection/connection.js index 7e11b297..b1802c8f 100644 --- a/app/src/main/resources/ui/connection/connection.js +++ b/app/src/main/resources/ui/connection/connection.js @@ -425,7 +425,9 @@ submitConnectionButton.addEventListener("click", async function () { } else if (ariaLabel === "Data source") { currConnection["type"] = inputField.value; } else { - currConnectionOptions[ariaLabel] = inputField.value; + if (inputField.value !== "") { + currConnectionOptions[ariaLabel] = inputField.value; + } } } }