diff options
author | Lionel <lionel.prat9@gmail.com> | 2020-10-06 19:12:31 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-06 19:12:31 +0200 |
commit | ecbf70a7ee51f643f10125dbede445a44a703c0c (patch) | |
tree | 629e3f511de6c5b6de1971c3970484030f579307 /rules | |
parent | b51bc0faa581c293832433904ee499086dbf47d7 (diff) | |
download | rspamd-ecbf70a7ee51f643f10125dbede445a44a703c0c.tar.gz rspamd-ecbf70a7ee51f643f10125dbede445a44a703c0c.zip |
fix potential error if fdtld and mdtld == nil
Diffstat (limited to 'rules')
-rw-r--r-- | rules/mid.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rules/mid.lua b/rules/mid.lua index 68a15136c..a7ffb27e1 100644 --- a/rules/mid.lua +++ b/rules/mid.lua @@ -53,7 +53,7 @@ local function mid_check_func(task) task:insert_result('MID_CONTAINS_FROM', 1.0) elseif (md and fd == md:lower()) then task:insert_result('MID_RHS_MATCH_FROM', 1.0) - elseif (md and mdtld:lower() == fdtld) then + elseif (mdtld ~= nil and fdtld ~= nil and mdtld:lower() == fdtld) then task:insert_result('MID_RHS_MATCH_FROMTLD', 1.0) end end |