ensure checkbox imports work on contacts
authorJamie McClelland <jm@mayfirst.org>
Fri, 4 Nov 2022 15:36:24 +0000 (11:36 -0400)
committerEileen McNaughton <emcnaughton@wikimedia.org>
Wed, 22 Feb 2023 00:24:57 +0000 (13:24 +1300)
See https://lab.civicrm.org/dev/core/-/issues/3850

CRM/Contact/Import/Parser/Contact.php

index 523924c4c40545f01d2ce74c3629388ebf22ecd2..f1b7b92b0e960b5575588a400c7fe743276bf377 100644 (file)
@@ -420,12 +420,7 @@ class CRM_Contact_Import_Parser_Contact extends CRM_Import_Parser {
               if ((strtolower($v2['label']) == strtolower(trim($v1))) ||
                 (strtolower($v2['value']) == strtolower(trim($v1)))
               ) {
-                if ($htmlType == 'CheckBox') {
-                  $params[$key][$v2['value']] = $formatted[$key][$v2['value']] = 1;
-                }
-                else {
-                  $params[$key][] = $formatted[$key][] = $v2['value'];
-                }
+                $params[$key][] = $formatted[$key][] = $v2['value'];
               }
             }
           }