From d0f1ddaec57577b13e5386223c7aa2b740a644bf Mon Sep 17 00:00:00 2001 From: Martin Benjamins Date: Fri, 26 Jul 2024 19:08:10 +0200 Subject: [PATCH] Fix result count --- wwwroot/files/naming.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wwwroot/files/naming.html b/wwwroot/files/naming.html index e610f60..4d7997a 100644 --- a/wwwroot/files/naming.html +++ b/wwwroot/files/naming.html @@ -238,6 +238,7 @@

M2 naming prefixes

const namingForm = document.getElementById("namingForm"); const submitButton = document.getElementById("submitButton"); const result = document.getElementById("result"); + const resultTitle = document.getElementById("resultTitle"); var Elements = { table: null, currentID: 0 @@ -280,7 +281,7 @@

M2 naming prefixes

}).then(function(response) { return response.text(); }).then(function (data) { - resultTitle.innerHTML = "Result (" + (data.split('\n').length - 1) + " names)"; + resultTitle.innerHTML = "Result (" + (data.split('\n').length) + " names)"; result.innerHTML = data; submitButton.disabled = false; submitButton.classList.remove("disabled");