diff --git a/responses.md b/responses.md index 9acb20c0eb5..9ad063e4dde 100644 --- a/responses.md +++ b/responses.md @@ -213,6 +213,8 @@ The `download` method may be used to generate a response that forces the user's return response()->download($pathToFile); return response()->download($pathToFile, $name, $headers); + + return response()->download($pathToFile)->deleteFileAfterSend(true); > {note} Symfony HttpFoundation, which manages file downloads, requires the file being downloaded to have an ASCII file name.