Skip to content

Commit

Permalink
when metric action is not defined, it reads a score causing a type er…
Browse files Browse the repository at this point in the history
…ror where the value should be a string and the actual action
  • Loading branch information
nishils committed Mar 1, 2023
1 parent 057ee1a commit 4f127cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plugins/lua/milter_headers.lua
Expand Up @@ -360,7 +360,7 @@ local function milter_headers(task)
local local_mod = settings.routines['x-rspamd-action']
if skip_wanted('x-rspamd-action') then return end
if not common['metric_action'] then
common['metric_action'] = task:get_metric_score()
common['metric_action'] = task:get_metric_action()
end
local action = common['metric_action']
if local_mod.remove then
Expand Down

0 comments on commit 4f127cf

Please sign in to comment.