From: monishdeb Date: Tue, 10 Mar 2015 06:11:27 +0000 (+0530) Subject: CRM-16064 fix - Contributions pricesets charge $1 more than selected X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=387fd5aa700ce6055bd5c48a9c273a65a3e66ef8;p=civicrm-core.git CRM-16064 fix - Contributions pricesets charge $1 more than selected https://issues.civicrm.org/jira/browse/CRM-16064 --- diff --git a/CRM/Contribute/Form/Contribution/Main.php b/CRM/Contribute/Form/Contribution/Main.php index 6ad81b8052..19ebeb6bae 100644 --- a/CRM/Contribute/Form/Contribution/Main.php +++ b/CRM/Contribute/Form/Contribution/Main.php @@ -1281,7 +1281,7 @@ class CRM_Contribute_Form_Contribution_Main extends CRM_Contribute_Form_Contribu $is_quick_config = CRM_Core_DAO::getFieldValue('CRM_Price_DAO_PriceSet', $priceSetId, 'is_quick_config'); if ($is_quick_config) { foreach ($this->_values['fee'] as $key => & $val) { - if ($val['name'] == 'other_amount' && $val['html_type'] == 'Text' && array_key_exists('price_' . $key, $params)) { + if ($val['name'] == 'other_amount' && $val['html_type'] == 'Text' && !empty($params['price_' . $key])) { $params['price_' . $key] = CRM_Utils_Rule::cleanMoney($params['price_' . $key]); //Clean out any currency symbols if ($params['price_' . $key] != 0) { foreach ($val['options'] as $optionKey => & $options) {