CRM-21853: Do not change 'is_multiple' unless included in the params
authorMichael Devery <michael@compucorp.co.uk>
Mon, 26 Mar 2018 10:59:54 +0000 (11:59 +0100)
committerMichael Devery <michael@compucorp.co.uk>
Mon, 26 Mar 2018 15:26:29 +0000 (16:26 +0100)
Also remove use of CRM_Utils_Array call since we're sure it's set

CRM/Core/BAO/CustomGroup.php

index 1ec8b471441f22c4622659c58ea7599d7c6a0c7a..21e4563142fdafb8517f734ba527ebf1c8b3c2b4 100644 (file)
@@ -128,8 +128,8 @@ class CRM_Core_BAO_CustomGroup extends CRM_Core_DAO_CustomGroup {
       $fields[] = 'is_public';
     }
     foreach ($fields as $field) {
-      if (isset($params[$field]) || $field == 'is_multiple') {
-        $group->$field = CRM_Utils_Array::value($field, $params, FALSE);
+      if (isset($params[$field])) {
+        $group->$field = $params[$field];
       }
     }
     $group->max_multiple = isset($params['is_multiple']) ? (isset($params['max_multiple']) &&