浏览代码

Update Shell.php

missing check
Grzesiek W 11 年之前
父节点
当前提交
58735c3ddc
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Console/Shell.php

+ 1 - 1
src/Console/Shell.php

@@ -608,7 +608,7 @@ class Shell
 
         $this->_io->out();
 
-        if (is_file($path) && empty($this->params['force'])) {
+        if (is_file($path) && empty($this->params['force']) && $this->interactive) {
             $this->_io->out(sprintf('<warning>File `%s` exists</warning>', $path));
             $key = $this->_io->askChoice('Do you want to overwrite?', ['y', 'n', 'q'], 'n');