summaryrefslogtreecommitdiffstats
path: root/apps/files/js/fileactions.js
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files/js/fileactions.js')
-rw-r--r--apps/files/js/fileactions.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/apps/files/js/fileactions.js b/apps/files/js/fileactions.js
index 703e543bf4b..af7c757276e 100644
--- a/apps/files/js/fileactions.js
+++ b/apps/files/js/fileactions.js
@@ -196,13 +196,12 @@ FileActions.register('all', 'Rename', OC.PERMISSION_UPDATE, function () {
FileList.rename(filename);
});
-
FileActions.register('dir', 'Open', OC.PERMISSION_READ, '', function (filename) {
- var dir = $('#dir').val();
+ var dir = $('#dir').val() || '/';
if (dir !== '/') {
dir = dir + '/';
}
- window.location = OC.linkTo('files', 'index.php') + '?dir=' + encodeURIComponent(dir + filename);
+ FileList.changeDirectory(dir + filename);
});
FileActions.setDefault('dir', 'Open');