Merge pull request #11045 from mepps/CRM-20304
[civicrm-core.git] / CRM / Utils / DeprecatedUtils.php
index 934a175d1f9ec6e2eef04b80e75b4c4a4ac02d9c..d720fb1ffec967ededfa2ad1171798816c90e42b 100644 (file)
@@ -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)) {