From ffb8d01ad13fcae4056ec32b11e34e8fd430a5c7 Mon Sep 17 00:00:00 2001 From: Arjan H Date: Fri, 12 Jan 2024 20:48:01 +0100 Subject: [PATCH] Fix default Common Name on create certificate --- gui/static/js/labca.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gui/static/js/labca.js b/gui/static/js/labca.js index 116718d..326c0af 100644 --- a/gui/static/js/labca.js +++ b/gui/static/js/labca.js @@ -153,7 +153,7 @@ $(function() { $('#o').blur(function() { var prefix = $(this).val().split(" ")[0]; - if ((prefix != "") && (($("#cn").val() == "Root CA") || ($("#cn").val() == "CA")) && ($(this).parent().parent().find(".error").length == 0)) { + if ((prefix != "") && (($("#cn").val() == "Root CA") || ($("#cn").val() == "CA")) && ($(this).parent().parent().find(".error").length == 1)) { $("#cn").val(prefix + " " + $("#cn").val()); } });