From 62bab1e353adfcb483ae4170aac1fa352904ee5b Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 13 Jan 2025 19:05:59 +1100 Subject: [PATCH] Return earlier if payment type = credit --- app/Livewire/Flow2/InvoicePay.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/Livewire/Flow2/InvoicePay.php b/app/Livewire/Flow2/InvoicePay.php index 79c303a119..a434dbf7c4 100644 --- a/app/Livewire/Flow2/InvoicePay.php +++ b/app/Livewire/Flow2/InvoicePay.php @@ -141,6 +141,9 @@ class InvoicePay extends Component $company_gateway = CompanyGateway::query()->find($company_gateway_id); + if(!$company_gateway) + return $this->required_fields = false; + $this->checkRequiredFields($company_gateway); }