fix file download

This commit is contained in:
2026-01-07 12:33:08 +01:00
parent 95be4fc5a9
commit 162688ceb4
2 changed files with 9 additions and 8 deletions

View File

@@ -96,12 +96,12 @@ class PilotServiceProvider extends ServiceProvider
if (isset($output['file'])) {
return response()->download(
$output['file']['contents'],
$output['file']['name'],
[
$output['file']['path'],
$output['file']['name'] ?? null,
! empty($output['file']['type']) ? [
'Content-Type' => $output['file']['type'],
]
);
] : []
)->deleteFileAfterSend(isset($output['file']['deleteAfterDownload']) ? $output['file']['deleteAfterDownload'] : false);
}
return response();