From 29990b77ab3bfc84c75faf0f39640141536a7818 Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Mon, 1 Sep 2014 14:18:11 +1200 Subject: [PATCH] CRM-15210 fix fatal on merge exports of non primary addresses The relationship check is preventing the fields from being transformed to the correct field names in contacts not-to-be-merged The possibility of the object not existing is adequately handled further down in the function. The check was added during svn-days but after 4.2.4 I no longer seem to be able to access what commit introduced it --- CRM/Export/BAO/Export.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CRM/Export/BAO/Export.php b/CRM/Export/BAO/Export.php index 7e78d6f310..cbbd318355 100644 --- a/CRM/Export/BAO/Export.php +++ b/CRM/Export/BAO/Export.php @@ -901,7 +901,7 @@ INSERT INTO {$componentTable} SELECT distinct gc.contact_id FROM civicrm_group_c if (is_object($relDAO) && $relationField == 'id') { $row[$field . $relationField] = $relDAO->contact_id; } - elseif ( is_object( $relDAO ) && is_array( $relationValue ) && $relationField == 'location' ) { + elseif (is_array( $relationValue ) && $relationField == 'location') { foreach ($relationValue as $ltype => $val) { foreach (array_keys($val) as $fld) { $type = explode('-', $fld); -- 2.25.1