From 4f127cf8dce3a329deea7ba18bc754a6ab4a22b6 Mon Sep 17 00:00:00 2001 From: Nishil Shah Date: Tue, 28 Feb 2023 18:05:42 -0800 Subject: [PATCH] when metric action is not defined, it reads a score causing a type error where the value should be a string and the actual action --- src/plugins/lua/milter_headers.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/lua/milter_headers.lua b/src/plugins/lua/milter_headers.lua index 1c35f89b4..02f50be27 100644 --- a/src/plugins/lua/milter_headers.lua +++ b/src/plugins/lua/milter_headers.lua @@ -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 -- 2.39.5