From 805d7f24d2851194502d7fe1e326830dd7c53f11 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Wed, 16 Jun 2021 21:15:32 +1000 Subject: [PATCH] Minor fixes for InvoiceController PDF --- app/Http/Controllers/InvoiceController.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/Http/Controllers/InvoiceController.php b/app/Http/Controllers/InvoiceController.php index e1cd61f3a032..76f137cc8a7c 100644 --- a/app/Http/Controllers/InvoiceController.php +++ b/app/Http/Controllers/InvoiceController.php @@ -793,9 +793,8 @@ class InvoiceController extends BaseController $contact = $invitation->contact; $invoice = $invitation->invoice; - $file = $invoice->service()->getInvoicePdf($contact); - - return response()->download($file, basename($file), ['Cache-Control:' => 'no-cache'])->deleteFileAfterSend(true);; + $file = $invoice->pdf_file_path($invitation); + return response()->download($file, basename($file), ['Cache-Control:' => 'no-cache'])->deleteFileAfterSend(true); }