From 2715507a9a04ef56163facaa9e89449830c7df4d Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 29 May 2023 07:29:14 +1000 Subject: [PATCH] minor fixes for live design previews --- app/Helpers/Invoice/InvoiceItemSum.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Helpers/Invoice/InvoiceItemSum.php b/app/Helpers/Invoice/InvoiceItemSum.php index 62999672eb0e..afb14ef5df2b 100644 --- a/app/Helpers/Invoice/InvoiceItemSum.php +++ b/app/Helpers/Invoice/InvoiceItemSum.php @@ -170,7 +170,7 @@ class InvoiceItemSum private function shouldCalculateTax(): self { - if (!$this->invoice->company->calculate_taxes || $this->invoice->company->account->isFreeHostedClient()) { + if (!$this->invoice->company?->calculate_taxes || $this->invoice->company->account->isFreeHostedClient()) { $this->calc_tax = false; return $this; }