aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorMarcin <M.Czarnecki1@uni.brighton.ac.uk>2017-02-21 00:38:46 +0000
committerGitHub <noreply@github.com>2017-02-21 00:38:46 +0000
commit20ad3f33d001b4dc8766c4d2a305d9d362d770b2 (patch)
treec36a8bea4d365ac71db75942f06a2276f5e60705 /apps
parenta4266f59ae68062988487cc972ba00f71e692920 (diff)
downloadnextcloud-server-20ad3f33d001b4dc8766c4d2a305d9d362d770b2.tar.gz
nextcloud-server-20ad3f33d001b4dc8766c4d2a305d9d362d770b2.zip
Fixed path in other folders search
Signed-off-by: Marcin Czarnecki <marcin.czarnecki@protonmail.com>
Diffstat (limited to 'apps')
-rw-r--r--apps/files/js/search.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files/js/search.js b/apps/files/js/search.js
index fa79d695165..140a66e346d 100644
--- a/apps/files/js/search.js
+++ b/apps/files/js/search.js
@@ -63,7 +63,7 @@
show size and last modified date on the right */
this.updateLegacyMimetype(result);
- var $pathDiv = $('<div class="path"></div>').text(result.path.substr(1));
+ var $pathDiv = $('<div class="path"></div>').text(result.path.substr(1, result.path.lastIndexOf("/")));
$row.find('td.info div.name').after($pathDiv).text(result.name);
$row.find('td.result a').attr('href', result.link);
@@ -80,7 +80,7 @@
show size and last modified date on the right */
this.updateLegacyMimetype(result);
- var $pathDiv = $('<div class="path"></div>').text(result.path.substr(1));
+ var $pathDiv = $('<div class="path"></div>').text(result.path.substr(1, result.path.lastIndexOf("/")));
$row.find('td.info div.name').after($pathDiv).text(result.name);
$row.find('td.result a').attr('href', result.link);