浏览代码

thrown exception when using an unsupported format

Benoît Merlet 12 年之前
父节点
当前提交
4a3c419e74
共有 1 个文件被更改,包括 1 次插入2 次删除
  1. 1 2
      src/Composer/Command/LicensesCommand.php

+ 1 - 2
src/Composer/Command/LicensesCommand.php

@@ -92,8 +92,7 @@ EOT
                 break;
 
             default:
-                $output->writeln(sprintf('Unsupported format "%s".  See help for supported formats.', $format));
-                break;
+                throw new \RuntimeException(sprintf('Unsupported format "%s".  See help for supported formats.', $format));
         }
     }
 }