]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Use mime from/rcpt if SMTP ones are missing
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 8 Jun 2017 09:17:09 +0000 (10:17 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 8 Jun 2017 09:17:09 +0000 (10:17 +0100)
src/plugins/lua/multimap.lua

index 0a1cf15b588a40bd55e2632540216e662e61a690..e2bde2a3211dcf03492fa2d40ab2ee7e614d8f32 100644 (file)
@@ -658,12 +658,18 @@ local function multimap_callback(task, rule)
       if task:has_recipients('smtp') then
         local rcpts = task:get_recipients('smtp')
         match_addr(rule, rcpts)
+      elseif task:has_recipients('mime') then
+        local rcpts = task:get_recipients('mime')
+        match_addr(rule, rcpts)
       end
     end,
     from = function()
       if task:has_from('smtp') then
         local from = task:get_from('smtp')
         match_addr(rule, from)
+      elseif task:has_from('mime') then
+        local from = task:get_from('mime')
+        match_addr(rule, from)
       end
     end,
     helo = function()