Skip to content

Commit 9be680d

Browse files
fix: extract file descriptor when items have nested 'file' key
When the frontend sends multiple files via 'Choose from Files', each item in the files array has the shape: { file: { path: '...' }, name: 'filename' } processFileData() was passing the whole item as 'file' to getNodeFromData(), creating a double-nested file.file.path structure that getNodeFromData() cannot resolve, triggering the 'No file source provided' exception. Fix: extract fileData['file'] if present, otherwise fall back to using fileData itself as the descriptor. Fixes #7343 Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
1 parent 46a8252 commit 9be680d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/Service/RequestSignatureService.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ private function processFileData(array $fileData, ?IUser $userManager, array $se
220220
$sourceNode = $this->fileService->getNodeFromData([
221221
'userManager' => $userManager,
222222
'name' => $name,
223-
'file' => $fileData,
223+
'file' => $fileData['file'] ?? $fileData,
224224
'settings' => $settings,
225225
]);
226226
}

0 commit comments

Comments
 (0)