Skip to content

Commit d5f19c1

Browse files
committed
Set proper root path for single file shares originating from other storages
Signed-off-by: Julius Härtl <jus@bitgrid.net>
1 parent 3f8f0f7 commit d5f19c1

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

apps/files_sharing/lib/SharedStorage.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,9 @@ private function init() {
127127
Filesystem::initMountPoints($this->superShare->getShareOwner());
128128
$sourcePath = $this->ownerView->getPath($this->superShare->getNodeId());
129129
list($this->nonMaskedStorage, $this->rootPath) = $this->ownerView->resolvePath($sourcePath);
130+
if ($this->nonMaskedStorage->getMountPoint() === $this->ownerView->getAbsolutePath($sourcePath)) {
131+
$this->rootPath = '/';
132+
}
130133
$this->storage = new PermissionsMask([
131134
'storage' => $this->nonMaskedStorage,
132135
'mask' => $this->superShare->getPermissions()

0 commit comments

Comments
 (0)