]> source.dussan.org Git - nextcloud-server.git/commitdiff
for external storages we never reach the path 'files', instead we need to leave the...
authorBjörn Schießle <schiessle@owncloud.com>
Wed, 29 May 2013 12:19:18 +0000 (14:19 +0200)
committerFlorin Peter <github@florin-peter.de>
Fri, 31 May 2013 10:24:21 +0000 (12:24 +0200)
lib/public/share.php

index afb5bc1491438cb6df712703f110f237bf26d1cf..0d4dc0f3fb7c75403c824b250abc4e5a7a9927ef 100644 (file)
@@ -141,9 +141,10 @@ class Share {
                $view = new \OC\Files\View('/' . $user . '/files/');
                $meta = $view->getFileInfo(\OC_Filesystem::normalizePath($path));
                $source = $meta['fileid'];
+               $parent = $meta['parent'];
                $cache = new \OC\Files\Cache\Cache($meta['storage']);
                
-               while ($path !== 'files') {
+               while ($path !== 'files' && $parent !== '-1') {
 
                        // Fetch all shares of this file path from DB
                        $query = \OC_DB::prepare(