diff options
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/Share20/Manager.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/private/Share20/Manager.php b/lib/private/Share20/Manager.php index b04f1acbd87..884ab4754f5 100644 --- a/lib/private/Share20/Manager.php +++ b/lib/private/Share20/Manager.php @@ -1419,10 +1419,12 @@ class Manager implements IManager { return $al; } - //Get node for the owner + //Get node for the owner and correct the owner in case of external storages $userFolder = $this->rootFolder->getUserFolder($owner); if ($path->getId() !== $userFolder->getId() && !$userFolder->isSubNode($path)) { - $path = $userFolder->getById($path->getId())[0]; + $nodes = $userFolder->getById($path->getId()); + $path = array_shift($nodes); + $owner = $path->getOwner()->getUID(); } $providers = $this->factory->getAllProviders(); |