浏览代码

Merge pull request #2615 from nextcloud/daita-sharecontroller

Download a file in a subfolder in a sharedlink is not working
tags/v11.0.0
Lukas Reschke 7 年前
父节点
当前提交
e49088315e
共有 1 个文件被更改,包括 4 次插入3 次删除
  1. 4
    3
      apps/files_sharing/lib/Controller/ShareController.php

+ 4
- 3
apps/files_sharing/lib/Controller/ShareController.php 查看文件

@@ -487,7 +487,7 @@ class ShareController extends Controller {
// Single file download
$this->singleFileDownloaded($share, $share->getNode());
} else if (!empty($files_list)) {
$this->fileListDownloaded($share, $files_list);
$this->fileListDownloaded($share, $files_list, $node);
} else {
// The folder is downloaded
$this->singleFileDownloaded($share, $share->getNode());
@@ -541,10 +541,11 @@ class ShareController extends Controller {
*
* @param Share\IShare $share
* @param array $files_list
* @param \OCP\Files\Folder $node
*/
protected function fileListDownloaded(Share\IShare $share, array $files_list) {
protected function fileListDownloaded(Share\IShare $share, array $files_list, \OCP\Files\Folder $node) {
foreach ($files_list as $file) {
$subNode = $share->getNode()->get($file);
$subNode = $node->get($file);
$this->singleFileDownloaded($share, $subNode);
}


正在加载...
取消
保存