CRM-15073 : fix overwrite of subtype for onbehalf org
authorCiviCRM <info@civicrm.org>
Mon, 18 Aug 2014 04:09:11 +0000 (09:39 +0530)
committerCiviCRM <info@civicrm.org>
Mon, 18 Aug 2014 04:09:11 +0000 (09:39 +0530)
CRM/Contribute/Form/Contribution/Confirm.php

index 85aa0167ff76fa7d34db93dc73545eb9df8374da..81384a8de62f2b1ef5d34c98ebd2c15f952a6afb 100644 (file)
@@ -1657,7 +1657,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr
 
       // CRM-6243 says to pick the first org even if more than one match
       if (count($dupeIDs) >= 1) {
-        $behalfOrganization['contact_id'] = $dupeIDs[0];
+        $behalfOrganization['contact_id'] = $orgID = $dupeIDs[0];
         // don't allow name edit
         unset($behalfOrganization['organization_name']);
       }