]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Avoid `nil` table 1608/head
authorAlexander Moisseev <moiseev@mezonplus.ru>
Thu, 27 Apr 2017 17:37:37 +0000 (20:37 +0300)
committerGitHub <noreply@github.com>
Thu, 27 Apr 2017 17:37:37 +0000 (20:37 +0300)
rules/misc.lua

index ccc52d8870c8547ed316f211733d67861797abc9..ab4a87508a6ab6a85fedf5502ce47407cd144ec0 100644 (file)
@@ -578,6 +578,7 @@ rspamd_config.INFO_TO_INFO_LU = {
       return false
     end
     local to = task:get_recipients('smtp')
+    if not to then return false end
     local found = false
     for _,r in ipairs(to) do
       if util.strequal_caseless(r['user'], 'info') then
@@ -609,4 +610,4 @@ rspamd_config.R_BAD_CTE_7BIT = {
   score = 4.0,
   description = 'Detects bad content-transfer-encoding for text parts',
   group = 'header'
-}
\ No newline at end of file
+}