From c22319afc61e5d51ae0b4219619fea816ed6a0ea Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20Peters?= Date: Wed, 3 May 2017 13:05:50 +0200 Subject: [PATCH] Fixes saving action scores in WebUI Variable elts was not updated and always returned the previously set values. --- interface/js/app/config.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/interface/js/app/config.js b/interface/js/app/config.js index 7b8ec9710..a5ec6c341 100644 --- a/interface/js/app/config.js +++ b/interface/js/app/config.js @@ -215,15 +215,15 @@ function($) { $('#actionsFormField').attr('disabled', true); } - var elts = loadActionsFromForm(); - $('#saveActionsClusterBtn').on('click', function() { + var elts = loadActionsFromForm(); rspamd.queryNeighbours('saveactions', null, null, "POST", {}, { data: elts, dataType: "json", }); }); $('#saveActionsBtn').on('click', function() { + var elts = loadActionsFromForm(); rspamd.queryLocal('saveactions', null, null, "POST", {}, { data: elts, dataType: "json", @@ -287,4 +287,4 @@ function($) { interface.getMaps = getMaps; return interface; -}); \ No newline at end of file +}); -- 2.39.5