From febe5109f0059a8553439f082dd854906e5c9ee2 Mon Sep 17 00:00:00 2001 From: diego-ramos Date: Mon, 21 Apr 2025 11:21:30 -0500 Subject: [PATCH] Fix error when sending a receipt of a sale without invoice (#4229) --- app/Controllers/Sales.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Controllers/Sales.php b/app/Controllers/Sales.php index 781777518..9a18bc119 100644 --- a/app/Controllers/Sales.php +++ b/app/Controllers/Sales.php @@ -989,7 +989,7 @@ class Sales extends Secure_Controller $text = $this->config['invoice_email_message']; $tokens = [ - new Token_invoice_sequence($sale_data['invoice_number']), + new Token_invoice_sequence($number), new Token_invoice_count('POS ' . $sale_data['sale_id']), new Token_customer((array)$sale_data) ];