[dev] Filters match all/any

Atif Ghaffar aghaffar@developer.ch
Sat, 08 Jun 2002 18:03:03 +0200



Jan Schneider wrote:
> That looks pretty interesting though I don't understand why it's necessary
> to convert the the old filter format to the new one. You can keep it as it
> is and let 'matchingrule' default to 'any' anywhere it is accessed.

because  in old format we are using a list of header keys and one field 
for text. In the new format there is no "text" value , the fields array 
is a hash with 'to' 'cc', etc as keys and the value to match as text.

On a running system, the filters will be in the old format and should be 
converted to the new format to work. I have 129 filters and dont want to 
loose them :)

F.Y.I.
-----

old format=

fitler {
  text => "some text",
  fields => ["array" , "of", "fields"]

}

new format=

filters {
  fields => {
   'to' => 'aghaffar@developer.ch',
   'subject' => 'some subject'
   ...
   ...
   ...
  }
}




> A patch would be nice.

Ok. I'll try to submit one today.

best regards



-- 
Atif Ghaffar
---------------------------.
           +41 78 845 31 64 ¦ tel
     aghaffar@developer.ch  ¦ email
     http://atifghaffar.com ¦ www
                    8206786 ¦ icq