summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-04-25 12:31:44 +0200
committerRobin Appelman <icewind@owncloud.com>2014-04-25 12:31:44 +0200
commit456ca0cf7d8fd259e58ea302b6849db5a001ce15 (patch)
tree2f22bed025d8ab2c96e3b4c3e102080fe368e304
parent3fc809dfd80a296d7da922a06f9e13d446b3d3f0 (diff)
downloadnextcloud-server-456ca0cf7d8fd259e58ea302b6849db5a001ce15.tar.gz
nextcloud-server-456ca0cf7d8fd259e58ea302b6849db5a001ce15.zip
fix paths of searchByMime results on substorages
-rw-r--r--lib/private/files/view.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/private/files/view.php b/lib/private/files/view.php
index 58dfc73dcf3..93d2c15c50b 100644
--- a/lib/private/files/view.php
+++ b/lib/private/files/view.php
@@ -1109,8 +1109,9 @@ class View {
if ($results) {
foreach ($results as $result) {
$internalPath = $result['path'];
- $result['path'] = $relativeMountPoint . $result['path'];
- $files[] = new FileInfo($mountPoint . $result['path'], $storage, $internalPath, $result);
+ $result['path'] = rtrim($relativeMountPoint . $result['path'], '/');
+ $path = rtrim($mountPoint . $internalPath, '/');
+ $files[] = new FileInfo($path, $storage, $internalPath, $result);
}
}
}