From ebacf2bd57ab8aec69a332c30d725204c8aeb6ac Mon Sep 17 00:00:00 2001 From: tiny-craft <137850705+tiny-craft@users.noreply.github.com> Date: Wed, 27 Sep 2023 19:34:24 +0800 Subject: [PATCH] fix: cannot save duplicate connection #24 --- frontend/src/components/dialogs/ConnectionDialog.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/frontend/src/components/dialogs/ConnectionDialog.vue b/frontend/src/components/dialogs/ConnectionDialog.vue index cb8fb81..f492d16 100644 --- a/frontend/src/components/dialogs/ConnectionDialog.vue +++ b/frontend/src/components/dialogs/ConnectionDialog.vue @@ -80,7 +80,10 @@ const onSaveConnection = async () => { }) // store new connection - const { success, msg } = await connectionStore.saveConnection(editName.value, generalForm.value) + const { success, msg } = await connectionStore.saveConnection( + isEditMode.value ? editName.value : null, + generalForm.value, + ) if (!success) { $message.error(msg) return