From: Andrew Lewis Date: Thu, 7 Sep 2017 17:43:11 +0000 (+0200) Subject: [Minor] Fix previous commit: avoid doing useless things X-Git-Tag: 1.7.0~664 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=37cb9f4869045a9f97c10b01dd20db28c6d8c641;p=thirdparty%2Frspamd.git [Minor] Fix previous commit: avoid doing useless things --- diff --git a/lualib/auth_results.lua b/lualib/auth_results.lua index 8f7e675532..5f4b2f896f 100644 --- a/lualib/auth_results.lua +++ b/lualib/auth_results.lua @@ -133,14 +133,14 @@ local function gen_auth_results(task, settings) end table.insert(hdr_parts, hdr) elseif auth_type == 'dkim' and key ~= 'none' then - local dkim_parts = {} if common.symbols[auth_types['dkim'][key]][1] then + local dkim_parts = {} local opts = common.symbols[auth_types['dkim'][key]][1]['options'] for _, v in ipairs(opts) do table.insert(dkim_parts, auth_type .. '=' .. key .. ' header.d=' .. v) end + table.insert(hdr_parts, table.concat(dkim_parts, '; ')) end - table.insert(hdr_parts, table.concat(dkim_parts, '; ')) elseif auth_type == 'arc' and key ~= 'none' then if common.symbols[auth_types['arc'][key]][1] then local opts = common.symbols[auth_types['arc'][key]][1]['options'] or {}