Skip to content

Commit 5f0c21c

Browse files
authored
Merge pull request #33734 from nextcloud/search-result-leading-slash
2 parents efb6411 + e9ba58c commit 5f0c21c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/private/Files/Node/Folder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ public function search($query) {
298298

299299
private function cacheEntryToFileInfo(IMountPoint $mount, string $appendRoot, ICacheEntry $cacheEntry): FileInfo {
300300
$cacheEntry['internalPath'] = $cacheEntry['path'];
301-
$cacheEntry['path'] = $appendRoot . $cacheEntry->getPath();
301+
$cacheEntry['path'] = rtrim($appendRoot . $cacheEntry->getPath(), '/');
302302
$subPath = $cacheEntry['path'] !== '' ? '/' . $cacheEntry['path'] : '';
303303
return new \OC\Files\FileInfo($this->path . $subPath, $mount->getStorage(), $cacheEntry['internalPath'], $cacheEntry, $mount);
304304
}

0 commit comments

Comments
 (0)