summaryrefslogtreecommitdiffstats
path: root/lib/private/connector/sabre/directory.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/connector/sabre/directory.php')
-rw-r--r--lib/private/connector/sabre/directory.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/connector/sabre/directory.php b/lib/private/connector/sabre/directory.php
index 6e028ca9daa..85756f112e7 100644
--- a/lib/private/connector/sabre/directory.php
+++ b/lib/private/connector/sabre/directory.php
@@ -230,7 +230,7 @@ class Directory extends \OC\Connector\Sabre\Node
*/
public function delete() {
- if (!$this->info->isDeletable()) {
+ if ($this->path === '' || $this->path === '/' || !$this->info->isDeletable()) {
throw new \Sabre\DAV\Exception\Forbidden();
}