summaryrefslogtreecommitdiffstats
path: root/apps/dav
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2017-02-28 10:27:24 +0100
committerJoas Schilling <coding@schilljs.com>2017-04-27 09:29:20 +0200
commit211a76eff3f23c2037b26bc8ea8e4da10f70e823 (patch)
tree6d265d94eaef50279bceb249f6517e04e55b6219 /apps/dav
parent614bd5c29419c9f45d4fa826539c544a6d7c2e26 (diff)
downloadnextcloud-server-211a76eff3f23c2037b26bc8ea8e4da10f70e823.tar.gz
nextcloud-server-211a76eff3f23c2037b26bc8ea8e4da10f70e823.zip
Add comment
Diffstat (limited to 'apps/dav')
-rw-r--r--apps/dav/lib/Connector/Sabre/Directory.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/dav/lib/Connector/Sabre/Directory.php b/apps/dav/lib/Connector/Sabre/Directory.php
index 579dbbabf44..435f47ee561 100644
--- a/apps/dav/lib/Connector/Sabre/Directory.php
+++ b/apps/dav/lib/Connector/Sabre/Directory.php
@@ -247,6 +247,8 @@ class Directory extends \OCA\DAV\Connector\Sabre\Node
}
try {
if (!$this->info->isReadable()) {
+ // return 403 instead of 404 because a 404 would make
+ // the caller believe that the collection itself does not exist
throw new Forbidden('No read permissions');
}
$folderContent = $this->fileView->getDirectoryContent($this->path);