diff options
author | Eric Wong <e@80x24.org> | 2017-06-23 00:47:23 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2017-06-23 00:47:23 +0000 |
commit | 403177efccc2b1c3883eb7b7dd3985d947828481 (patch) | |
tree | cd0220da5ef2e76a81df65b3192aea8708d3b86f /lib | |
parent | b66b53809698130ec4758066f373ca7362fba375 (diff) | |
download | public-inbox-403177efccc2b1c3883eb7b7dd3985d947828481.tar.gz |
The RubyLang filter is strict about what messages it rejects, so the spam learning path will not auto-train or remove messages missing X-Mail-Count headers.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/PublicInbox/WatchMaildir.pm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/PublicInbox/WatchMaildir.pm b/lib/PublicInbox/WatchMaildir.pm index 8588f16c..c15e1384 100644 --- a/lib/PublicInbox/WatchMaildir.pm +++ b/lib/PublicInbox/WatchMaildir.pm @@ -108,6 +108,7 @@ sub _remove_spam { $im->remove($mime); if (my $scrub = _scrubber_for($ibx)) { my $scrubbed = $scrub->scrub($mime) or return; + $scrubbed == 100 and return; $im->remove($scrubbed); } }; @@ -169,7 +170,9 @@ sub _try_path { return unless ($v && $v =~ $wm->[1]); } if (my $scrub = _scrubber_for($inbox)) { - $mime = $scrub->scrub($mime) or return; + my $ret = $scrub->scrub($mime) or return; + $ret == 100 and return; + $mime = $ret; } _force_mid($mime); |