Fix the wrong variable reference

This commit is contained in:
Benjamin Beganović 2021-05-10 13:35:38 +02:00
parent 580628b7f9
commit 50ad75b516

View File

@ -76,9 +76,9 @@ class QuoteController extends Controller
} }
if ($quotes->count() == 1) { if ($quotes->count() == 1) {
return response()->streamDownload(function () use ($invoices) { return response()->streamDownload(function () use ($quotes) {
echo file_get_contents($invoices->first()->pdf_file_path()); echo file_get_contents($quotes->first()->pdf_file_path());
}, basename($invoices->first()->pdf_file_path()), ['Cache-Control:' => 'no-cache']); }, basename($quotes->first()->pdf_file_path()), ['Cache-Control:' => 'no-cache']);
//return response()->download(TempFile::path($invoices->first()->pdf_file_path()), basename($quotes->first()->pdf_file_path())); //return response()->download(TempFile::path($invoices->first()->pdf_file_path()), basename($quotes->first()->pdf_file_path()));
} }