summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-08-06 14:57:54 +0200
committerRobin Appelman <icewind@owncloud.com>2014-08-07 13:44:49 +0200
commit221312709407ba01432acda98e20d2ab8e73d205 (patch)
treebb8e06098df860d8628c97a286d0aa810bcfcbcf /apps
parent9598efc7cd52904d36a6d91d2119013df17acd9b (diff)
downloadnextcloud-server-221312709407ba01432acda98e20d2ab8e73d205.tar.gz
nextcloud-server-221312709407ba01432acda98e20d2ab8e73d205.zip
trim leading slash
Diffstat (limited to 'apps')
-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 d0a6d4a0112..fbbff472b9d 100644
--- a/apps/files_sharing/lib/cache.php
+++ b/apps/files_sharing/lib/cache.php
@@ -438,7 +438,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);