From: Vsevolod Stakhov Date: Thu, 22 Apr 2021 13:08:47 +0000 (+0100) Subject: [Minor] Lua_magic: Make an exclusion for message parts X-Git-Tag: 3.0~468 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=adefe59d6f1273d4b9613bf29f19bca954d6ad45;p=thirdparty%2Frspamd.git [Minor] Lua_magic: Make an exclusion for message parts --- diff --git a/lualib/lua_magic/heuristics.lua b/lualib/lua_magic/heuristics.lua index 042bfde3f8..5863897bc4 100644 --- a/lualib/lua_magic/heuristics.lua +++ b/lualib/lua_magic/heuristics.lua @@ -427,7 +427,7 @@ exports.text_part_heuristic = function(part, log_obj, _) local ext, weight = process_top_detected(res) - if weight and weight >= 40 then + if weight and weight >= 40 and mtype ~= 'message' then return ext, weight end end