浏览代码

Ask confirmation when is run as admin

Use return instead of exit for the Application to run cleanly
Ahammar Yassine 6 年之前
父节点
当前提交
0fd4ef6d8e
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Composer/Console/Application.php

+ 1 - 1
src/Composer/Console/Application.php

@@ -210,7 +210,7 @@ class Application extends BaseApplication
                         
                         if ($io->isInteractive()) {
                             if (!$io->askConfirmation('<info>Continue as root/super user</info> [<comment>yes</comment>]? ', true)) {
-                                exit(0);
+                                return 0;
                             }
                         }
                     }