fix permissions of mountpoints
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
18b5e2fced
commit
75b3b72d89
|
@ -1351,8 +1351,12 @@ class View {
|
|||
return false;
|
||||
}
|
||||
|
||||
if ($mount instanceof MoveableMount && $internalPath === '') {
|
||||
$data['permissions'] |= \OCP\Constants::PERMISSION_DELETE;
|
||||
if ($internalPath === '') {
|
||||
if ($mount instanceof MoveableMount) {
|
||||
$data['permissions'] = $data['permissions'] | \OCP\Constants::PERMISSION_UPDATE | \OCP\Constants::PERMISSION_DELETE;
|
||||
} else {
|
||||
$data['permissions'] = $data['permissions'] & (\OCP\Constants::PERMISSION_ALL - (\OCP\Constants::PERMISSION_UPDATE | \OCP\Constants::PERMISSION_DELETE));
|
||||
}
|
||||
}
|
||||
|
||||
$owner = $this->getUserObjectForOwner($storage->getOwner($internalPath));
|
||||
|
|
Loading…
Reference in New Issue