Data\Filter: SORT_NATURAL only for PHP >= 5.4

This commit is contained in:
Thomas Gelf 2014-11-12 11:47:42 +01:00
parent 5851886877
commit f0ca81d7af
1 changed files with 1 additions and 1 deletions

View File

@ -79,7 +79,7 @@ abstract class Filter
}
}
krsort($operators, SORT_NATURAL);
krsort($operators, version_compare(PHP_VERSION, '5.4.0') >= 0 ? SORT_NATURAL : SORT_REGULAR);
foreach ($operators as $id => $operator) {
$f = $filter->getById($id);
if ($f->getOperatorName() !== $operator) {