diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2017-10-30 21:06:35 +0100 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2017-10-30 21:06:35 +0100 |
commit | 638be96232e8e35345509ba6f6a83905a312a57a (patch) | |
tree | 523df12aeba757cca0879fcbbe8a4cf8a20f4ded /apps/files_sharing/lib | |
parent | 5672f14fd1218945bd6d585d231554a8481525ae (diff) | |
download | nextcloud-server-638be96232e8e35345509ba6f6a83905a312a57a.tar.gz nextcloud-server-638be96232e8e35345509ba6f6a83905a312a57a.zip |
Do not error when downloading from a numeric public subfolder
Fixes #6820
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps/files_sharing/lib')
-rw-r--r-- | apps/files_sharing/lib/Controller/ShareController.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/Controller/ShareController.php b/apps/files_sharing/lib/Controller/ShareController.php index ed9ad33417a..700ac220804 100644 --- a/apps/files_sharing/lib/Controller/ShareController.php +++ b/apps/files_sharing/lib/Controller/ShareController.php @@ -458,6 +458,10 @@ class ShareController extends Controller { if ($files_list === null) { $files_list = [$files]; } + // Just in case $files is a single int like '1234' + if (!is_array($files_list)) { + $files_list = [$files_list]; + } } $userFolder = $this->rootFolder->getUserFolder($share->getShareOwner()); |