From 1fbcf0cd6aa99b085a1de2b83dfee00bf1000501 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Mon, 9 Aug 2021 10:35:50 +0100 Subject: [PATCH] [Minor] Dmarc_report: Fix bcc_addrs usage --- lualib/rspamadm/dmarc_report.lua | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lualib/rspamadm/dmarc_report.lua b/lualib/rspamadm/dmarc_report.lua index e3c59db79..1b0bc7f24 100644 --- a/lualib/rspamadm/dmarc_report.lua +++ b/lualib/rspamadm/dmarc_report.lua @@ -551,9 +551,17 @@ local function prepare_report(opts, start_time, rep_key) {'DEL', rep_key}) end + local report_rcpts = lua_util.str_split(rcpt_string, ',') + + if report_settings.bcc_addrs then + for _,b in ipairs(report_settings.bcc_addrs) do + table.insert(report_rcpts, b) + end + end + return { message = message, - rcpts = lua_util.str_split(rcpt_string .. (bcc_string or ''), ','), + rcpts = report_rcpts, reporting_domain = reporting_domain } end -- 2.39.5