From: Vsevolod Stakhov Date: Fri, 17 Nov 2017 18:59:21 +0000 (+0000) Subject: [Fix] Allow to check negative scores in force_actions X-Git-Tag: 1.7.0~430 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fb4265765e0a2932c1d43c5167482feee8bc461a;p=thirdparty%2Frspamd.git [Fix] Allow to check negative scores in force_actions MFH: rspamd-1.6 --- diff --git a/src/plugins/lua/force_actions.lua b/src/plugins/lua/force_actions.lua index d8d29b3231..a733a14257 100644 --- a/src/plugins/lua/force_actions.lua +++ b/src/plugins/lua/force_actions.lua @@ -44,7 +44,7 @@ local function gen_cb(expr, act, pool, message, subject, raction, honor, limit) local function process_atom(atom, task) local f_ret = task:has_symbol(atom) if f_ret then - f_ret = task:get_symbol(atom)[1].score + f_ret = math.abs(task:get_symbol(atom)[1].score) if f_ret < 0.001 then -- Adjust some low score to distinguish from pure zero f_ret = 0.001