]> source.dussan.org Git - nextcloud-server.git/commitdiff
fixes oc-668
authorThomas Mueller <thomas.mueller@tmit.eu>
Mon, 18 Jun 2012 21:33:02 +0000 (23:33 +0200)
committerThomas Mueller <thomas.mueller@tmit.eu>
Tue, 19 Jun 2012 20:37:25 +0000 (22:37 +0200)
lib/helper.php

index 3de7b3fdc107f7192770d525f44cd9f951309188..080df8613ecb38a6a282fbb30ba839e7033fe186 100644 (file)
@@ -377,6 +377,12 @@ class OC_Helper {
 
                        //trim the character set from the end of the response
                        $mimeType=substr($reply,0,strrpos($reply,' '));
+
+                       //trim ; 
+                       if (strpos($mimeType, ';') !== false) {
+                               $mimeType = strstr($mimeType, ';', true);
+                       }
+
                }
                if ($mimeType=='application/octet-stream') {
                        // Fallback solution: (try to guess the type by the file extension