summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/lib/sharedstorage.php
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-11-04 15:16:58 +0100
committerRobin Appelman <icewind@owncloud.com>2014-11-06 18:31:40 +0100
commit7ecd2207157efffabdf5ec8f36c6f4accc348fc4 (patch)
tree4442d98174d010328449f21b49fc812b905d383a /apps/files_sharing/lib/sharedstorage.php
parent9c79c2fa17be40a6c7b8212c6e7a89c2f6470d04 (diff)
downloadnextcloud-server-7ecd2207157efffabdf5ec8f36c6f4accc348fc4.tar.gz
nextcloud-server-7ecd2207157efffabdf5ec8f36c6f4accc348fc4.zip
Setup shared mounts for the correct user when setting up the filesystem for the non-logged in user
Diffstat (limited to 'apps/files_sharing/lib/sharedstorage.php')
-rw-r--r--apps/files_sharing/lib/sharedstorage.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php
index 5ce15d9a012..19ee6085e47 100644
--- a/apps/files_sharing/lib/sharedstorage.php
+++ b/apps/files_sharing/lib/sharedstorage.php
@@ -397,7 +397,7 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage {
}
public static function setup($options) {
- $shares = \OCP\Share::getItemsSharedWith('file');
+ $shares = \OCP\Share::getItemsSharedWithUser('file', $options['user']);
$manager = Filesystem::getMountManager();
$loader = Filesystem::getLoader();
if (!\OCP\User::isLoggedIn() || \OCP\User::getUser() != $options['user']
@@ -411,7 +411,8 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage {
$options['user_dir'] . '/' . $share['file_target'],
array(
'share' => $share,
- ),
+ 'user' => $options['user']
+ ),
$loader
);
$manager->addMount($mount);