close imapConnection
[squirrelmail.git] / class / mime.class.php
index 1da8622610d0708ff3491b263aedc76f044e4c6d..7b818a703c570e722ead18a5fe1bef93d8a0c835 100644 (file)
@@ -763,21 +763,20 @@ class message {
                }
                $found = true;          
            }
-           $found = true;              
        } else if ( $this->type0 == 'text' &&
              ( $this->type1 == 'plain' ||
                $this->type1 == 'html' ||
               $this->type1 == 'message') &&
              isset($this->entity_id) ) {
             if (count($this->entities) == 0) {
-               if ($this->header->disposition->name != 'attachment') {
+               if (strtolower($this->header->disposition->name) != 'attachment') {
                   $entity[] = $this->entity_id;
                }
             }
         } 
        $i = 0;
        while ( isset($this->entities[$i]) &&  !$found &&
-               ($this->entities[$i]->header->disposition->name 
+               (strtolower($this->entities[$i]->header->disposition->name) 
                != 'attachment') &&
                ($this->entities[$i]->type0 != 'message' && 
                  $this->entities[$i]->type1 != 'rfc822' )