diff --git a/CRM/Custom/Form/Group.php b/CRM/Custom/Form/Group.php index 90b6947adb68..6139759f17e0 100644 --- a/CRM/Custom/Form/Group.php +++ b/CRM/Custom/Form/Group.php @@ -115,11 +115,10 @@ public static function formRule($fields, $files, $self) { //validate group title as well as name. $title = $fields['title']; $name = CRM_Utils_String::munge($title, '_', 64); - $query = 'select count(*) from civicrm_custom_group where ( name like %1 OR title like %2 ) and id != %3'; + $query = 'select count(*) from civicrm_custom_group where ( name like %1) and id != %2'; $grpCnt = CRM_Core_DAO::singleValueQuery($query, array( 1 => array($name, 'String'), - 2 => array($title, 'String'), - 3 => array((int) $self->_id, 'Integer'), + 2 => array((int) $self->_id, 'Integer'), )); if ($grpCnt) { $errors['title'] = ts('Custom group \'%1\' already exists in Database.', array(1 => $title));