From 6ce097e8cbed152c457341c84624825822e3c354 Mon Sep 17 00:00:00 2001 From: Justin Freeman Date: Tue, 1 Aug 2017 12:19:43 +1000 Subject: [PATCH] CIVICRM-230 CRM-17040 Import Contributions using External Ids causes soft credit to be wrongly associated --- CRM/Utils/DeprecatedUtils.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CRM/Utils/DeprecatedUtils.php b/CRM/Utils/DeprecatedUtils.php index 934a175d1f..d720fb1ffe 100644 --- a/CRM/Utils/DeprecatedUtils.php +++ b/CRM/Utils/DeprecatedUtils.php @@ -484,7 +484,9 @@ function _civicrm_api3_deprecated_check_contact_dedupe($params) { if ($field == NULL || $field === '') { continue; } - if (is_array($field)) { + // CRM-17040, Considering only primary contact when importing contributions. So contribution inserts into primary contact + // instead of soft credit contact. + if (is_array($field) && $key != "soft_credit") { foreach ($field as $value) { $break = FALSE; if (is_array($value)) { -- 2.25.1