Use (int) cast instead of intval() function for performance reasons and to unify it.

This commit is contained in:
euromark 2014-09-10 15:52:57 +02:00
parent 58bf005c09
commit e77f96d8b7
12 changed files with 25 additions and 25 deletions

View file

@ -290,8 +290,8 @@ class Hash {
$count = count($path);
$last = $count - 1;
foreach ($path as $i => $key) {
if (is_numeric($key) && intval($key) > 0 || $key === '0') {
$key = intval($key);
if (is_numeric($key) && (int)$key > 0 || $key === '0') {
$key = (int)$key;
}
if ($op === 'insert') {
if ($i === $last) {