From: Andrew Lewis Date: Fri, 17 Feb 2017 08:11:31 +0000 (+0200) Subject: [Minor] Force actions: deal with null better X-Git-Tag: 1.5.0~94^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=6e854fe00b66591db773f7875748268f7b1a9e94;p=rspamd.git [Minor] Force actions: deal with null better --- diff --git a/src/plugins/lua/force_actions.lua b/src/plugins/lua/force_actions.lua index 6c01afc2b..e5c309c24 100644 --- a/src/plugins/lua/force_actions.lua +++ b/src/plugins/lua/force_actions.lua @@ -57,7 +57,7 @@ local function gen_cb(expr, act, pool, message, subject) if subject then task:set_metric_subject(subject) end - if message then + if type(message) == 'string' then task:set_pre_result(act, message) else task:set_pre_result(act)