protected function keyExistsRecursive($keys, $data_array)
{
$thiskey = current($keys);
if (is_numeric($thiskey)) {
// force numeric strings to be integers
$thiskey = (int) $thiskey;
}
if (array_key_exists($thiskey, $data_array)) {
if (sizeof($keys) == 1) {
return true;
} elseif ($data_array[$thiskey] instanceof \ArrayObject) {
unset($keys[key($keys)]);
return $this->keyExistsRecursive($keys, $data_array[$thiskey]);
}
}
return false;
}