From: AL Date: Tue, 25 Oct 2016 11:05:50 +0000 (+0300) Subject: Update mx_check.lua X-Git-Tag: 1.4.0~196^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=1719feacffeec853a1ab3d4cfcfaf3f335d53b49;p=thirdparty%2Frspamd.git Update mx_check.lua --- diff --git a/src/plugins/lua/mx_check.lua b/src/plugins/lua/mx_check.lua index 51b3029379..39ba95b0b5 100644 --- a/src/plugins/lua/mx_check.lua +++ b/src/plugins/lua/mx_check.lua @@ -43,11 +43,11 @@ local function mx_check(task) if from and from[1] and from[1]['domain'] and not from[2] then mx_domain = from[1]['domain'] else - mx_domain = rspamd_util.get_tld(task:get_helo()) - end + mx_domain = task:get_helo() - if not mx_domain then - return + if mx_domain then + mx_domain = rspamd_util.get_tld(mx_domain) + end end local valid = false