diff options
author | Vincent Petry <pvince81@owncloud.com> | 2016-03-07 11:55:55 +0100 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2016-03-07 21:50:45 +0100 |
commit | 4bc0eb546c1fd3e3a281ab6ae9eae4ca14dc47db (patch) | |
tree | 1f53a735bf808bd87fec1b7d0e089df5a01d8a72 | |
parent | f9a14e5c548537c07e6b15c10798084e33f3b2c8 (diff) | |
download | nextcloud-server-4bc0eb546c1fd3e3a281ab6ae9eae4ca14dc47db.tar.gz nextcloud-server-4bc0eb546c1fd3e3a281ab6ae9eae4ca14dc47db.zip |
Remove "files" arg from download URL in public link page
When no files were specified for download, it means folder download.
In this case, no need to pass an empty "files" argument.
-rw-r--r-- | apps/files_sharing/js/public.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/files_sharing/js/public.js b/apps/files_sharing/js/public.js index b684e08be8b..cdeeb598e40 100644 --- a/apps/files_sharing/js/public.js +++ b/apps/files_sharing/js/public.js @@ -142,9 +142,11 @@ OCA.Sharing.PublicApp = { } var path = dir || FileList.getCurrentDirectory(); var params = { - path: path, - files: filename + path: path }; + if (filename) { + params.files = filename; + } return OC.generateUrl('/s/' + token + '/download') + '?' + OC.buildQueryString(params); }; |