]> source.dussan.org Git - nextcloud-server.git/commitdiff
when scanning a folder that is a mountpoint, use the root of the mount for checking...
authorRobin Appelman <icewind@owncloud.com>
Wed, 16 May 2012 23:47:58 +0000 (01:47 +0200)
committerRobin Appelman <icewind@owncloud.com>
Wed, 16 May 2012 23:47:58 +0000 (01:47 +0200)
lib/filecache.php

index 9ec307cc8129bec673b8515de7588d5245e2c196..a94349e19cb9c58387f3477384282c238cab61a3 100644 (file)
@@ -564,9 +564,13 @@ class OC_FileCache{
                }
                if(!$view->is_readable($path)) return; //cant read, nothing we can do
                clearstatcache();
-               $stat=$view->stat($path);
                $mimetype=$view->getMimeType($path);
-               $writable=$view->is_writable($path);
+               $stat=$view->stat($path);
+               if($mimetype=='httpd/unix-directory'){
+                       $writable=$view->is_writable($path.'/');
+               }else{
+                       $writable=$view->is_writable($path);
+               }
                $stat['mimetype']=$mimetype;
                $stat['writable']=$writable;
                if($path=='/'){