From 323a4b91cd0113c46d633624fd674c7604f752aa Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Jun 18 2015 12:35:46 +0000 Subject: Use the name of the button instead of checking for a value For all the submit actions but the ones related to dropping a comment we want to do async, for dropping a comment, we need to go the standard way. --- diff --git a/pagure/templates/issue.html b/pagure/templates/issue.html index 831ef15..9a8d11b 100644 --- a/pagure/templates/issue.html +++ b/pagure/templates/issue.html @@ -360,7 +360,7 @@ function try_async_comment(form) { var _url = form.action + "?js=1"; var _data = $(form).serialize(); var btn = $(document.activeElement); - if (btn[0].value){ + if (btn[0].name == 'drop_comment'){ _data += '&drop_comment=' + btn[0].value; return true; }