Code

Don't display warnings like 'x may not appear before y'
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 15 Mar 2007 11:51:02 +0000 (11:51 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 15 Mar 2007 11:51:02 +0000 (11:51 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@5788 594d385d-05f5-0310-b6e9-bd551577e9d8

include/sieve/class_parser.inc
include/sieve/class_semantics.inc
include/sieve/class_sieveManagement.inc

index 7ca1f9e3b25e349eb5a6f04db852aee016c1b742..933232ecab081da86ff37986a0f662a2153f58e9 100644 (file)
@@ -109,7 +109,7 @@ class Parser
                $last = $this->tree_->getLastNode($parent_id);
                if (!$semantics->validAfter($last['text']))
                {
-                       return $this->error_('"'. $token['text'] .'" may not appear after "'. $last['text'] .'"');
+                       #return $this->error_('"'. $token['text'] .'" may not appear after "'. $last['text'] .'"');
                }
 
                // Process eventual arguments
index e37d5c6313541234afa95c7d207867dbcef42ea4..6fa7c4b7d29ee49b5ac263acf3cb66057a68c99f 100644 (file)
@@ -163,7 +163,7 @@ class Semantics
                                                array('occurrences' => '?', 'regex' => ':mime', 'name' => 'mime')
                                        )),
                                        array('class' => 'string', 'occurrences' => '1', 'values' => array(
-                                               array('occurrences' => '1', 'regex' => '".*"', 'name' => 'reason')
+                                               array('occurrences' => '1', 'regex' => '.*', 'name' => 'reason')
                                        ))
                                )
                        );
@@ -479,6 +479,7 @@ class Semantics
                $arg = &$this->s_['arguments'][0];
                foreach ($arg['values'] as $val)
                {
+
                        if (preg_match('/^'. $val['regex'] .'$/m', $text))
                        {
                                // Check if the argument value needs a 'require'
index 0bf128d216c0566b0b5ad79df7f28f4de21f0b39..99237f5394fe07df8fcb41b3016574a41766172a 100644 (file)
@@ -268,7 +268,6 @@ class sieveManagement extends plugin
     /* Save currently edited sieve script. */
     if(isset($_POST['save_sieve_changes'])){
       $chk = $this->current_handler->check();
-      $chk =array();
       if(!count($chk)){
 
         $sc = $this->scripts[$this->current_script]['SCRIPT'];