diff --git a/bin/cli.class.php b/bin/cli.class.php index 8cdcc9e8e7c1..dff79069f40a 100644 --- a/bin/cli.class.php +++ b/bin/cli.class.php @@ -294,8 +294,7 @@ private function _bootstrap() { * @return bool */ private function _validateOptions() { - $required = $this->_required_arguments; - while (list(, $var) = each($required)) { + foreach ($this->_required_arguments as $var) { $index = '_' . $var; if (empty($this->$index)) { $missing_arg = '--' . $var;