Refactor code structure for improved readability and maintainability
This commit is contained in:
@@ -87,7 +87,7 @@ try {
|
||||
$invoice_language = 'US'; // Default fallback
|
||||
}
|
||||
|
||||
list($data,$customer_email,$order_id) = generateInvoice($invoice_cust,$orderId,$invoice_language);
|
||||
list($data,$invoice_customer_email,$order_id) = generateInvoice($invoice_cust,$orderId,$invoice_language);
|
||||
|
||||
//CREATE PDF
|
||||
$dompdf->loadHtml($data);
|
||||
@@ -102,7 +102,7 @@ try {
|
||||
//++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
//Send to PHPMailer
|
||||
//++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
send_mail_by_PHPMailer($customer_email, $subject, $data, $attachment, $subject);
|
||||
send_mail_by_PHPMailer($invoice_customer_email, $subject, $data, $attachment, $subject);
|
||||
|
||||
if(invoice_bookkeeping){
|
||||
send_mail_by_PHPMailer(email_bookkeeping, $subject, $data, $attachment, $subject);
|
||||
|
||||
Reference in New Issue
Block a user