From 12ff43420f99232b6c42e2cbfa86e576aa057f37 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Sun, 25 Oct 2015 09:35:23 +0200 Subject: [PATCH] Bug fixes --- app/Models/Account.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Models/Account.php b/app/Models/Account.php index 904f03896cb3..743fc166b760 100644 --- a/app/Models/Account.php +++ b/app/Models/Account.php @@ -260,7 +260,7 @@ class Account extends Eloquent $invoice->is_quote = true; } - if ($this->hasClientNumberPattern($invoice) && !$client) { + if ($this->hasClientNumberPattern($invoice) && !$clientId) { // do nothing, we don't yet know the value } else { $invoice->invoice_number = $this->getNextInvoiceNumber($invoice);