Fix for bug on filters plugin which allows user to select INBOX as a
[squirrelmail.git] / plugins / filters / filters.php
index 8261c27..3c80671 100644 (file)
@@ -210,6 +210,11 @@ function filter_search_and_delete($imap_stream, $where, $what, $where_to, $user_
                                   $should_expunge) {
     global $languages, $squirrelmail_language, $allow_charset_search, $imap_server_type;
 
+    if (strtolower($where_to) == 'inbox') {
+        return array();
+    }
+
+
     if ($user_scan == 'new') {
         $category = 'UNSEEN';
     } else {
@@ -793,4 +798,4 @@ function do_error($string) {
     echo $string;
     echo "</font></p>\n";
 }
-?>
\ No newline at end of file
+?>