Skip to content
Snippets Groups Projects
Commit 0e2079a1 authored by colemanw's avatar colemanw
Browse files

One last eval CRM-12743

----------------------------------------
* CRM-12743: Eliminate use of eval in core code
  http://issues.civicrm.org/jira/browse/CRM-12743

----------------------------------------
* CRM-12743:
  http://issues.civicrm.org/jira/browse/CRM-12743
* CRM-12743::
  http://issues.civicrm.org/jira/browse/CRM-12743:
parent 9f092434
No related branches found
No related tags found
No related merge requests found
......@@ -142,9 +142,8 @@ class CRM_Activity_Page_AJAX {
foreach ($clientRelationships as $key => $row) {
$sortArray[$key] = $row[$sort];
}
$sort_type = "SORT_".strtoupper($sortOrder);
$sort_function = "array_multisort(\$sortArray, ".$sort_type.", \$clientRelationships);";
eval($sort_function);
$sort_type = "SORT_" . strtoupper($sortOrder);
array_multisort($sortArray, constant($sort_type), $clientRelationships);
//limit the rows
$allClientRelationships = $clientRelationships;
......@@ -239,10 +238,8 @@ class CRM_Activity_Page_AJAX {
$sortArray[$key] = $row[$sort];
}
$sort_type = "SORT_".strtoupper($sortOrder);
$sort_function = "array_multisort(\$sortArray, ".$sort_type.", \$caseRelationships);";
eval($sort_function);
$sort_type = "SORT_" . strtoupper($sortOrder);
array_multisort($sortArray, constant($sort_type), $caseRelationships);
//limit rows display
$allCaseRelationships = $caseRelationships;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment