}
}
- return CRM_Utils_Array::value($surveyId, $ufIds);
+ return $ufIds[$surveyId] ?? NULL;
}
/**
public static function isFieldHasLocationType($fieldTitle) {
foreach (CRM_Contact_BAO_Contact::importableFields() as $key => $field) {
if ($field['title'] === $fieldTitle) {
- return CRM_Utils_Array::value('hasLocationType', $field);
+ return $field['hasLocationType'] ?? NULL;
}
}
return FALSE;
*/
public static function checkContributeSettings($name) {
$contributeSettings = Civi::settings()->get('contribution_invoice_settings');
- return CRM_Utils_Array::value($name, $contributeSettings);
+ return $contributeSettings[$name] ?? NULL;
}
/**
public static function get($name, $attribute = NULL) {
$comp = CRM_Utils_Array::value($name, self::_info());
if ($attribute) {
- return CRM_Utils_Array::value($attribute, $comp->info);
+ return $comp->info[$attribute] ?? NULL;
}
return $comp;
}
*/
public function getButtonName() {
$data = &$this->container();
- return CRM_Utils_Array::value('_qf_button_name', $data);
+ return $data['_qf_button_name'] ?? NULL;
}
/**
return $month;
}
- return CRM_Utils_Array::value('m', $src['credit_card_exp_date']);
+ return $src['credit_card_exp_date']['m'] ?? NULL;
}
/**
* @return int
*/
public static function getCreditCardExpirationYear($src) {
- return CRM_Utils_Array::value('Y', $src['credit_card_exp_date']);
+ return $src['credit_card_exp_date']['Y'] ?? NULL;
}
/**
throw new CRM_Core_Exception("Failure: Missing Parameter $name");
}
else {
- return CRM_Utils_Array::value($name, $this->_invoiceData);
+ return $this->_invoiceData[$name] ?? NULL;
}
}
if ($values === FALSE) {
return FALSE;
}
- return CRM_Utils_Array::value($key, $values);
+ return $values[$key] ?? NULL;
}
/**
if ($values === FALSE) {
return FALSE;
}
- return CRM_Utils_Array::value($key, $values);
+ return $values[$key] ?? NULL;
}
/**
self::$accountOptionValues[$cacheKey] = CRM_Core_OptionGroup::values($optionGroupName, FALSE, FALSE, FALSE, $condition);
}
if ($id) {
- return CRM_Utils_Array::value($id, self::$accountOptionValues[$cacheKey]);
+ return self::$accountOptionValues[$cacheKey][$id] ?? NULL;
}
return self::$accountOptionValues[$cacheKey];
$session =& $this->_session[$this->_key][$prefix];
}
- return CRM_Utils_Array::value($name, $session);
+ return $session[$name] ?? NULL;
}
/**
* @return mixed
*/
public function get_event_in_cart_by_event_id($event_id) {
- return CRM_Utils_Array::value($event_id, $this->events_in_carts);
+ return $this->events_in_carts[$event_id] ?? NULL;
}
/**
);
}
if ($id) {
- return CRM_Utils_Array::value($id, self::$pcPage);
+ return self::$pcPage[$id] ?? NULL;
}
return self::$pcPage;
}
if (!$invoicing) {
return '';
}
- return CRM_Utils_Array::value('tax_term', $invoiceSettings);
+ return $invoiceSettings['tax_term'] ?? NULL;
}
/**
return TRUE;
}
$invoiceSettings = Civi::settings()->get('contribution_invoice_settings');
- return CRM_Utils_Array::value('invoicing', $invoiceSettings);
+ return $invoiceSettings['invoicing'] ?? NULL;
}
/**
*/
public static function getTaxTerm() {
$invoiceSettings = Civi::settings()->get('contribution_invoice_settings');
- return CRM_Utils_Array::value('tax_term', $invoiceSettings);
+ return $invoiceSettings['tax_term'] ?? NULL;
}
}
if (array_key_exists('options', $this->_logTables[$entity]['bracket_info']) &&
$entityID
) {
- return CRM_Utils_Array::value($entityID, $this->_logTables[$entity]['bracket_info']['options']);
+ return $this->_logTables[$entity]['bracket_info']['options'][$entityID] ?? NULL;
}
}
}
if (!$lookup) {
$lookup = CRM_Contact_BAO_Relationship::buildOptions("is_permission_a_b");
};
- return CRM_Utils_Array::value($key, $lookup);
+ return $lookup[$key] ?? NULL;
}
/**
$params = [1 => [$path, 'String']];
$valId[$path] = CRM_Core_DAO::singleValueQuery($sql, $params);
}
- return CRM_Utils_Array::value($path, $valId);
+ return $valId[$path] ?? NULL;
}
/**
* The previous page URL
*/
public static function refererPath() {
- return CRM_Utils_Array::value('HTTP_REFERER', $_SERVER);
+ return $_SERVER['HTTP_REFERER'] ?? NULL;
}
/**
$result = [];
CRM_Financial_BAO_FinancialTypeAccount::retrieve($searchParams, $result);
- return CRM_Utils_Array::value('financial_account_id', $result);
+ return $result['financial_account_id'] ?? NULL;
}
/**