Commit fe5b36c0 authored by mattwire's avatar mattwire
Browse files

Merge branch 'emailActivityID' into 'master'

Fix PHP notices when CC/BCC emails are defined without being linked to a contact

See merge request !11
parents cbeaf60d 8c3fab5b
......@@ -167,6 +167,9 @@ class CRM_Msgtplblocker_Activity {
protected function getEmailUrlString(array $emailIDs): string {
$urlString = '';
foreach ($emailIDs as $email) {
if (!isset($this->contactEmails[$email])) {
continue;
}
$contactURL = CRM_Utils_System::url('civicrm/contact/view', ['reset' => 1, 'force' => 1, 'cid' => $this->contactEmails[$email]['contact_id']], TRUE);
$urlString .= "<a href='{$contactURL}'>" . $this->contactEmails[$email]['contact.display_name'] . '</a>';
}
......
......@@ -3,6 +3,7 @@
## 1.6
* Check for emailActivityID param before creating activity - allows for activity creation to be disabled by passing in `emailActivityID` (if the caller already created the email activity) works with eg. emailApi - see [emailapi!32](https://lab.civicrm.org/extensions/emailapi/-/merge_requests/32).
* Fix PHP notices when CC/BCC emails are defined without being linked to a contact.
## 1.5
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment