X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FCore%2FPseudoConstant.php;h=9950cf10f540e0ef8a741bc548373fdf2cfa0401;hb=e345d7fca665c1d1964721043e62a4b61b3205b2;hp=96f9bba4231419d29d0b3dec4cd4e39a9c52a96c;hpb=a6491ceec03e64e45e127222ae268187c652f5b7;p=civicrm-core.git diff --git a/CRM/Core/PseudoConstant.php b/CRM/Core/PseudoConstant.php index 96f9bba423..9950cf10f5 100644 --- a/CRM/Core/PseudoConstant.php +++ b/CRM/Core/PseudoConstant.php @@ -54,10 +54,9 @@ class CRM_Core_PseudoConstant { private static $cache; /** - * @deprecated Please use the buildOptions() method in the appropriate BAO object. - * * activity type * @var array + * @deprecated Please use the buildOptions() method in the appropriate BAO object. */ private static $activityType; @@ -92,10 +91,9 @@ class CRM_Core_PseudoConstant { private static $countryIsoCode; /** - * @deprecated Please use the buildOptions() method in the appropriate BAO object. - * * group * @var array + * @deprecated Please use the buildOptions() method in the appropriate BAO object. */ private static $group; @@ -136,10 +134,9 @@ class CRM_Core_PseudoConstant { private static $worldRegions; /** - * @deprecated Please use the buildOptions() method in the appropriate BAO object. - * * activity status * @var array + * @deprecated Please use the buildOptions() method in the appropriate BAO object. */ private static $activityStatus; @@ -223,14 +220,12 @@ class CRM_Core_PseudoConstant { if ($options && $flip) { $options = array_flip($options); } - $customField->free(); return $options; } // Core field: load schema $dao = new $daoName(); $fieldSpec = $dao->getFieldSpec($fieldName); - $dao->free(); // Ensure we have the canonical name for this field $fieldName = CRM_Utils_Array::value('name', $fieldSpec, $fieldName); @@ -316,7 +311,6 @@ class CRM_Core_PseudoConstant { // Get list of fields for the option table $dao = new $daoName(); $availableFields = array_keys($dao->fieldKeys()); - $dao->free(); $select = "SELECT %1 AS id, %2 AS label"; $from = "FROM %3"; @@ -378,7 +372,6 @@ class CRM_Core_PseudoConstant { while ($dao->fetch()) { $output[$dao->id] = $dao->label; } - $dao->free(); // Localize results if (!empty($params['localize']) || $pseudoconstant['table'] == 'civicrm_country' || $pseudoconstant['table'] == 'civicrm_state_province') { $I18nParams = []; @@ -414,7 +407,7 @@ class CRM_Core_PseudoConstant { * * @param string $baoName * @param string $fieldName - * @param string|Int $key + * @param string|int $key * * TODO: Accept multivalued input? * @@ -436,7 +429,7 @@ class CRM_Core_PseudoConstant { * * @param string $baoName * @param string $fieldName - * @param string|Int $key + * @param string|int $key * * @return bool|null|string * FALSE if the given field has no associated option list @@ -456,7 +449,7 @@ class CRM_Core_PseudoConstant { * * @param string $baoName * @param string $fieldName - * @param string|Int $value + * @param string|int $value * * @return bool|null|string|int * FALSE if the given field has no associated option list @@ -1524,7 +1517,6 @@ WHERE id = %1 return CRM_Extension_System::singleton()->getMapper()->getActiveModuleFiles($fresh); } - /** * Get all tax rates. * @@ -1551,7 +1543,7 @@ WHERE id = %1 else { $value[] = $option['values'][0]['value']; } - $where = 'AND efa.account_relationship IN (' . implode(', ', $value) . ' )'; + $where = 'AND efa.account_relationship IN (' . implode(', ', $value) . ' )'; } else { $where = '';