summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/lib/sharedstorage.php
diff options
context:
space:
mode:
authorMichael Gapczynski <mtgap@owncloud.com>2013-05-02 17:47:11 -0400
committerMichael Gapczynski <mtgap@owncloud.com>2013-05-02 17:47:11 -0400
commit7039421efc80f3551026d3f16ba6887e7be02234 (patch)
tree337169030bac344b8e951cf916ec63ea913faae3 /apps/files_sharing/lib/sharedstorage.php
parent8a5e88b21cf95f8d0f964ee012f15e447644a10f (diff)
downloadnextcloud-server-7039421efc80f3551026d3f16ba6887e7be02234.tar.gz
nextcloud-server-7039421efc80f3551026d3f16ba6887e7be02234.zip
Fix retrieving of mount points for shared storage, fix #3218
Diffstat (limited to 'apps/files_sharing/lib/sharedstorage.php')
-rw-r--r--apps/files_sharing/lib/sharedstorage.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php
index 2facad0f7e2..5c23a9eb0d0 100644
--- a/apps/files_sharing/lib/sharedstorage.php
+++ b/apps/files_sharing/lib/sharedstorage.php
@@ -72,8 +72,8 @@ class Shared extends \OC\Files\Storage\Common {
if (!isset($source['fullPath'])) {
\OC\Files\Filesystem::initMountPoints($source['fileOwner']);
$mount = \OC\Files\Filesystem::getMountByNumericId($source['storage']);
- if ($mount) {
- $this->files[$target]['fullPath'] = $mount->getMountPoint().$source['path'];
+ if (is_array($mount)) {
+ $this->files[$target]['fullPath'] = $mount[key($mount)]->getMountPoint().$source['path'];
} else {
$this->files[$target]['fullPath'] = false;
}