sievec

Doug Barton dougb at dougbarton.us
Fri Mar 17 08:23:29 EET 2017


Your pattern seems a little too complicated. See below.

On 03/16/2017 02:20 PM, Robert Moskowitz wrote:

>   if exists "X-Spam-Flag" {

This isn't needed. If the flag doesn't exist, the 'if header ...' line 
won't match. You're doing two tests for every message where one is all 
that's needed.

>     if header :contains "X-Spam-Flag" "NO" {

You can just do "YES" here, and go straight to the command (fileinto). 
Yes/No is a boolean flag, it will either be one or the other.

>     fileinto "Spam";
>     stop;

It's not clear that you need the 'stop' here.

hope this helps,

Doug


More information about the dovecot mailing list