]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Fix dynamic scoring of subject symbols
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 28 Apr 2016 11:13:41 +0000 (12:13 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 28 Apr 2016 11:13:41 +0000 (12:13 +0100)
Reported by: @moisseev

rules/misc.lua

index 048bae149bc1d819bfcce67eddc7a1c338a30b8c..01fe3f5aa0d1fe3d3638673d0c347f9c513a7064 100644 (file)
@@ -38,7 +38,7 @@ reconf['R_FLASH_REDIR_IMGSHACK'] = '/^(?:http:\\/\\/)?img\\d{1,5}\\.imageshack\\
 local function test_subject(task, check_function, rate)
   local function normalize_linear(a, x)
       local f = a * x
-      return (( f < 1 ) and f or 1), tostring(x)
+      return true, (( f < 1 ) and f or 1), tostring(x)
   end
 
   local sbj = task:get_header('Subject')