From c9f8a28dc55369c5e6648ea5792dbc1d341eff2c Mon Sep 17 00:00:00 2001 From: Seamus Lee Date: Sat, 30 Jul 2016 07:14:12 +1000 Subject: [PATCH] Remove duplicated code and add a note about what this is all about --- CRM/Contribute/Form/Task/PDF.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/CRM/Contribute/Form/Task/PDF.php b/CRM/Contribute/Form/Task/PDF.php index 7304458e06..e1003561c9 100644 --- a/CRM/Contribute/Form/Task/PDF.php +++ b/CRM/Contribute/Form/Task/PDF.php @@ -162,10 +162,6 @@ AND {$this->_componentClause}"; $params = $this->controller->exportValues($this->_name); $elements = self::getElements($this->_contributionIds, $params, $this->_contactIds); - $fromEmail = $params['fromEmailAddress']; - $from = CRM_Utils_Array::value($fromEmail, $this->_emails); - $fromDetails = explode(' <', $from); - foreach ($elements['details'] as $contribID => $detail) { $input = $ids = $objects = array(); @@ -203,6 +199,7 @@ AND {$this->_componentClause}"; $values = array(); if (isset($params['fromEmailAddress']) && !$elements['createPdf']) { + // CRM-19129 Allow useres the choice of From Email to send the receipt from. $fromEmail = $params['fromEmailAddress']; $from = CRM_Utils_Array::value($fromEmail, $this->_emails); $fromDetails = explode(' <', $from); -- 2.25.1