From 8433b5e58369e2d3688540be08f79fba6e1ffa5c Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Mon, 24 Feb 2020 12:40:16 +0100 Subject: [PATCH] ui: fix automatic slug generation --- passbook/static/static/passbook/pf.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/passbook/static/static/passbook/pf.js b/passbook/static/static/passbook/pf.js index 00edd94fd..99f8609cd 100644 --- a/passbook/static/static/passbook/pf.js +++ b/passbook/static/static/passbook/pf.js @@ -49,6 +49,6 @@ document.querySelectorAll("input[name=name]").forEach((input) => { input.addEventListener("input", (e) => { const form = e.target.closest("form"); const slugField = form.querySelector("input[name=slug]"); - slugField.value = convertToSlug(slugField.value); + slugField.value = convertToSlug(e.target.value); }); });