aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2014-11-11 15:20:36 +0100
committerVincent Petry <pvince81@owncloud.com>2014-11-11 15:20:36 +0100
commit4b943a48108045d893b56243a3866b2c02faf55d (patch)
treeeb4ccfafdd21d56c037f107cc21f647ea065cd94
parent9368de5a8be5b77804fe7b9b1c8d66d5161f7f76 (diff)
downloadnextcloud-server-4b943a48108045d893b56243a3866b2c02faf55d.tar.gz
nextcloud-server-4b943a48108045d893b56243a3866b2c02faf55d.zip
Fix root path handling for WebDAV ext storage
Added missing cleanPath() call that converts "/" to "" when calling SabreDAV. This is needed because SabreDAV will discard its base URL when passing "/".
-rw-r--r--lib/private/files/storage/dav.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/private/files/storage/dav.php b/lib/private/files/storage/dav.php
index 7f53704e94f..26fa69408a8 100644
--- a/lib/private/files/storage/dav.php
+++ b/lib/private/files/storage/dav.php
@@ -433,6 +433,7 @@ class DAV extends \OC\Files\Storage\Common {
public function getPermissions($path) {
$this->init();
+ $path = $this->cleanPath($path);
$response = $this->client->propfind($this->encodePath($path), array('{http://owncloud.org/ns}permissions'));
if (isset($response['{http://owncloud.org/ns}permissions'])) {
return $this->parsePermissions($response['{http://owncloud.org/ns}permissions']);
@@ -477,6 +478,7 @@ class DAV extends \OC\Files\Storage\Common {
*/
public function hasUpdated($path, $time) {
$this->init();
+ $path = $this->cleanPath($path);
try {
$response = $this->client->propfind($this->encodePath($path), array(
'{DAV:}getlastmodified',