<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.7 |
+ | CiviCRM version 5 |
+--------------------------------------------------------------------+
| Copyright CiviCRM LLC (c) 2004-2018 |
+--------------------------------------------------------------------+
*/
private static function _addWhereAdd(&$customGroupDAO, $entityType, $entityID = NULL, $allSubtypes = FALSE) {
$addSubtypeClause = FALSE;
+ // This function isn't really accessible with user data but since the string
+ // is not passed as a param to the query CRM_Core_DAO::escapeString seems like a harmless
+ // precaution.
+ $entityType = CRM_Core_DAO::escapeString($entityType);
switch ($entityType) {
case 'Contact':
}
break;
- case 'Case':
- case 'Location':
- case 'Address':
- case 'Activity':
- case 'Contribution':
- case 'Membership':
- case 'Participant':
+ default:
$customGroupDAO->whereAdd("extends IN ('$entityType')");
break;
}