2
0
Antione LUCAS 11 лет назад
Родитель
Сommit
79ce9f8d35
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      library/Zend/Console/Getopt.php

+ 1 - 1
library/Zend/Console/Getopt.php

@@ -789,7 +789,7 @@ class Zend_Console_Getopt
         $realFlag = $this->_ruleMap[$flag];
         $realFlag = $this->_ruleMap[$flag];
         switch ($this->_rules[$realFlag]['param']) {
         switch ($this->_rules[$realFlag]['param']) {
             case 'required':
             case 'required':
-                if (count($argv) > 0) {
+                if (count($argv) > 0 && substr($argv[0], 0, 1) != '-') {
                     $param = array_shift($argv);
                     $param = array_shift($argv);
                     $this->_checkParameterType($realFlag, $param);
                     $this->_checkParameterType($realFlag, $param);
                 } else {
                 } else {