From dd02dc82a5fe8a45b6598a6e4399ba99883534bb Mon Sep 17 00:00:00 2001 From: Zoey Date: Mon, 26 Jun 2023 17:42:33 +0200 Subject: [PATCH] Update php/public/forms.js Co-authored-by: Simon L. Signed-off-by: Zoey --- php/public/forms.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/php/public/forms.js b/php/public/forms.js index 940e4ee3..52c72b92 100644 --- a/php/public/forms.js +++ b/php/public/forms.js @@ -41,7 +41,7 @@ function showPassword(id) { let passwordField = document.getElementById(id); - if (passwordField.value !== "" && passwordField.type !== "text") { + if (passwordField.type === "password" && passwordField.value !== "") { passwordField.type = "text"; } else if (passwordField.value === "" && passwordField.type !== "password") { passwordField.type = "password";