*/
public function privacy(&$values) {
list($name, $op, $value, $grouping) = $values;
- //fixed for profile search listing CRM-4633
if (is_array($value)) {
if (in_array(key($value), CRM_Core_DAO::acceptedSQLOperators(), TRUE)) {
$op = key($value);
$value = $value[$op];
}
}
- if (strpbrk($value, "[")) {
- $value = CRM_Core_DAO::escapeString($value);
- if (in_array("!{$op}", CRM_Core_DAO::acceptedSQLOperators(), TRUE)) {
- $op = "!{$op}";
- $this->_where[$grouping][] = "contact_a.{$name} $op $value";
- }
- }
- else {
- CRM_Utils_Type::validate($value, 'Integer');
- $this->_where[$grouping][] = "contact_a.{$name} $op $value";
- }
$field = $this->_fields[$name] ?? NULL;
+ CRM_Utils_Type::validate($value, 'Integer');
+ $this->_where[$grouping][] = "contact_a.{$name} $op $value";
$op = CRM_Utils_Array::value($op, CRM_Core_SelectValues::getSearchBuilderOperators(), $op);
$title = $field ? $field['title'] : $name;
$this->_qill[$grouping][] = "$title $op $value";