diff --git a/app/Models/Invoice.php b/app/Models/Invoice.php index bef7c61c..39cd3165 100644 --- a/app/Models/Invoice.php +++ b/app/Models/Invoice.php @@ -443,7 +443,8 @@ class Invoice extends Model implements HasMedia $data['invoice'] = $this->toArray(); $data['customer'] = $this->customer->toArray(); $data['company'] = Company::find($this->company_id); - $data['body'] = $this->getEmailBody($data['body']); + $data['subject'] = $this->getEmailString($data['subject']); + $data['body'] = $this->getEmailString($data['body']); $data['attach']['data'] = ($this->getEmailAttachmentSetting()) ? $this->getPDFData() : null; return $data; @@ -635,7 +636,7 @@ class Invoice extends Model implements HasMedia return $this->getFormattedString($this->notes); } - public function getEmailBody($body) + public function getEmailString($body) { $values = array_merge($this->getFieldsArray(), $this->getExtraFields());