External mount does not get DELETE and UPDATE if readonly

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2018-03-08 19:53:17 +01:00
parent db96b0bb0b
commit 953691abb2
No known key found for this signature in database
GPG Key ID: F941078878347C0C
1 changed files with 1 additions and 1 deletions

View File

@ -272,7 +272,7 @@ abstract class Node implements \Sabre\DAV\INode {
$mountpointpath = substr($mountpointpath, 0, -1); $mountpointpath = substr($mountpointpath, 0, -1);
} }
if ($mountpointpath === $this->info->getPath()) { if (!$mountpoint->getOption('readonly', false) && $mountpointpath === $this->info->getPath()) {
$permissions |= \OCP\Constants::PERMISSION_DELETE | \OCP\Constants::PERMISSION_UPDATE; $permissions |= \OCP\Constants::PERMISSION_DELETE | \OCP\Constants::PERMISSION_UPDATE;
} }
} }