Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix(TaskProcessing): Set up fs in getFileContentsInternal
Signed-off-by: Marcel Klehr <[email protected]>
  • Loading branch information
marcelklehr committed Nov 26, 2024
commit 3ac14af26b01fb1c630e52de4fc3ae52edef7051
3 changes: 3 additions & 0 deletions core/Controller/TaskProcessingApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,9 @@ private function getFileContentsInternal(Task $task, int $fileId): Http\DataDown
if (!in_array($fileId, $ids)) {
return new DataResponse(['message' => $this->l->t('Not found')], Http::STATUS_NOT_FOUND);
}
if ($task->getUserId() !== null) {
\OC_Util::setupFS($task->getUserId());
}
$node = $this->rootFolder->getFirstNodeById($fileId);
if ($node === null) {
$node = $this->rootFolder->getFirstNodeByIdInPath($fileId, '/' . $this->rootFolder->getAppDataDirectoryName() . '/');
Expand Down
Loading