From: Andrew Lewis Date: Sat, 23 Nov 2013 11:23:24 +0000 (+0200) Subject: Don't use key as symbol if returncodes given and unknown is false X-Git-Tag: 0.6.0~21^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fpull%2F4%2Fhead;p=rspamd.git Don't use key as symbol if returncodes given and unknown is false --- diff --git a/src/plugins/lua/rbl.lua b/src/plugins/lua/rbl.lua index 13d18d4fc..d46e0a33d 100644 --- a/src/plugins/lua/rbl.lua +++ b/src/plugins/lua/rbl.lua @@ -7,7 +7,6 @@ -- rbls { -- spamhaus { -- rbl = "zen.spamhaus.org"; --- symbol = "RBL_ZEN"; -- ipv4 = true; -- ipv6 = false; -- unknown = false; @@ -147,7 +146,7 @@ for key,rbl in pairs(opts['rbls']) do end end end - if not rbl['symbol'] then + if not rbl['symbol'] and type(rbl['returncodes']) ~= 'nil' and not rbl['unknown'] then rbl['symbol'] = key end if type(rspamd_config.get_api_version) ~= 'nil' then