From: Dave Greenberg Date: Tue, 25 Feb 2014 17:33:29 +0000 (-0800) Subject: CRM-14266 - include all system FROM emails. X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=c52a8fcc0ef9acd01ac8a30d25bdc36997f65861;p=civicrm-core.git CRM-14266 - include all system FROM emails. ---------------------------------------- * CRM-14266: send receipt from contrib/event/membership should list all configured FROM email addresses http://issues.civicrm.org/jira/browse/CRM-14266 --- diff --git a/CRM/Core/BAO/Email.php b/CRM/Core/BAO/Email.php index d3e5be77b3..5d67769386 100644 --- a/CRM/Core/BAO/Email.php +++ b/CRM/Core/BAO/Email.php @@ -287,10 +287,12 @@ AND reset_date IS NULL $contactID = $session->get('userID'); $fromEmailValues = array(); - // add the domain email id - $domainEmail = CRM_Core_BAO_Domain::getNameAndEmail(); - $domainEmail = "$domainEmail[0] <$domainEmail[1]>"; - $fromEmailValues[$domainEmail] = htmlspecialchars($domainEmail); + // add all configured FROM email addresses + $domainFrom = CRM_Core_OptionGroup::values('from_email_address'); + foreach (array_keys($domainFrom) as $k) { + $domainEmail = $domainFrom[$k]; + $fromEmailValues[$domainEmail] = htmlspecialchars($domainEmail); + } // add logged in user's active email ids if ($contactID) {