소스 검색

Simplify conditional block

Antoine Hérault 14 년 전
부모
커밋
d9f00ca7be
1개의 변경된 파일1개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 3
      src/Symfony/Component/Console/Input/ArgvInput.php

+ 1 - 3
src/Symfony/Component/Console/Input/ArgvInput.php

@@ -229,10 +229,8 @@ class ArgvInput extends Input
             $value = $option->isValueOptional() ? $option->getDefault() : true;
         }
 
-        if ($option->isArray() && isset($this->options[$name])) {
+        if ($option->isArray()) {
             $this->options[$name][] = $value;
-        } else if ($option->isArray()) {
-            $this->options[$name] = array($value);
         } else {
             $this->options[$name] = $value;
         }