From: Alexander Moisseev Date: Thu, 27 Apr 2017 17:37:37 +0000 (+0300) Subject: [Minor] Avoid `nil` table X-Git-Tag: 1.6.0~309^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=15a73c7bed4cd205c7215bf7b0fd8daeffa0edae;p=rspamd.git [Minor] Avoid `nil` table --- diff --git a/rules/misc.lua b/rules/misc.lua index ccc52d887..ab4a87508 100644 --- a/rules/misc.lua +++ b/rules/misc.lua @@ -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 +}