From 2f4f4ffa5c6207cf56fdc17de664e0347e23c69a Mon Sep 17 00:00:00 2001 From: Martchus Date: Thu, 14 Mar 2024 00:43:12 +0100 Subject: [PATCH] Ignore buttons when making query parameter for form --- srv/static/js/ajaxhelper.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/srv/static/js/ajaxhelper.js b/srv/static/js/ajaxhelper.js index 6d0ac22..996dc9a 100644 --- a/srv/static/js/ajaxhelper.js +++ b/srv/static/js/ajaxhelper.js @@ -90,7 +90,7 @@ function makeFormQueryParameter(form) continue; // if we disable a form element or hide it via CSS we also don't want to submit its data } const type = formElement.type; - if ((type === 'checkbox' || type === 'radio') && !formElement.checked) { + if ((type === 'button') || ((type === 'checkbox' || type === 'radio') && !formElement.checked)) { continue; } const name = formElement.name;