summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-08-06 14:57:54 +0200
committerRobin Appelman <icewind@owncloud.com>2014-08-06 14:57:54 +0200
commiteb8683e6eeb0baa81395118f261cbfe6f002f411 (patch)
tree5a9eb096c161fafa0b5073f963e03dd7a54a0055 /apps/files_sharing
parent12207ec0c7c725dce6b25d8c70306ced9bdc0410 (diff)
downloadnextcloud-server-eb8683e6eeb0baa81395118f261cbfe6f002f411.tar.gz
nextcloud-server-eb8683e6eeb0baa81395118f261cbfe6f002f411.zip
trim leading slash
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/lib/cache.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_sharing/lib/cache.php b/apps/files_sharing/lib/cache.php
index adea07e5f7b..e4fd85fd2a7 100644
--- a/apps/files_sharing/lib/cache.php
+++ b/apps/files_sharing/lib/cache.php
@@ -405,7 +405,7 @@ class Shared_Cache extends Cache {
public function getPathById($id, $pathEnd = '') {
// direct shares are easy
if ($id === $this->storage->getSourceId()) {
- return $pathEnd;
+ return ltrim($pathEnd, '/');
} else {
// if the item is a direct share we try and get the path of the parent and append the name of the item to it
list($parent, $name) = $this->getParentInfo($id);