diff --git a/apps/files_sharing/lib/SharedStorage.php b/apps/files_sharing/lib/SharedStorage.php index 67868b512c3e1..a2337cb14d61e 100644 --- a/apps/files_sharing/lib/SharedStorage.php +++ b/apps/files_sharing/lib/SharedStorage.php @@ -127,6 +127,9 @@ private function init() { Filesystem::initMountPoints($this->superShare->getShareOwner()); $sourcePath = $this->ownerView->getPath($this->superShare->getNodeId()); list($this->nonMaskedStorage, $this->rootPath) = $this->ownerView->resolvePath($sourcePath); + if ($this->nonMaskedStorage->getMountPoint() === $this->ownerView->getAbsolutePath($sourcePath)) { + $this->rootPath = '/'; + } $this->storage = new PermissionsMask([ 'storage' => $this->nonMaskedStorage, 'mask' => $this->superShare->getPermissions()