diff options
author | Robin Appelman <icewind@owncloud.com> | 2012-05-17 01:47:58 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2012-05-17 01:47:58 +0200 |
commit | c1ba4deb72cf1515ed000453cc6b31fac56f5f96 (patch) | |
tree | 177f96ba8c7dcb31cdf5fcafe395f8f9e15dda9b /lib/filecache.php | |
parent | 58adeaa80a65cb307736eb8f0040ea18b468e419 (diff) | |
download | nextcloud-server-c1ba4deb72cf1515ed000453cc6b31fac56f5f96.tar.gz nextcloud-server-c1ba4deb72cf1515ed000453cc6b31fac56f5f96.zip |
when scanning a folder that is a mountpoint, use the root of the mount for checking if a folder is writable instead of the folder
Diffstat (limited to 'lib/filecache.php')
-rw-r--r-- | lib/filecache.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/filecache.php b/lib/filecache.php index 9ec307cc812..a94349e19cb 100644 --- a/lib/filecache.php +++ b/lib/filecache.php @@ -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=='/'){ |