From: Elliott Eggleston Date: Mon, 8 Aug 2016 18:20:48 +0000 (-0400) Subject: Don't clobber contributionRecur currency on edit X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=8f7b45b0e81e1988f6bd72de311c6b34c41fb4b1;p=civicrm-core.git Don't clobber contributionRecur currency on edit When editing an existing contribution_recur without specifying a currency, do not change the record to the default currency. --- diff --git a/CRM/Contribute/BAO/ContributionRecur.php b/CRM/Contribute/BAO/ContributionRecur.php index 0159fbbc83..99c49a2f5a 100644 --- a/CRM/Contribute/BAO/ContributionRecur.php +++ b/CRM/Contribute/BAO/ContributionRecur.php @@ -85,7 +85,7 @@ class CRM_Contribute_BAO_ContributionRecur extends CRM_Contribute_DAO_Contributi $recurring->id = CRM_Utils_Array::value('id', $params); // set currency for CRM-1496 - if (!isset($recurring->currency)) { + if (empty($params['id']) && !isset($recurring->currency)) { $config = CRM_Core_Config::singleton(); $recurring->currency = $config->defaultCurrency; }