Throw an exception instead of a fatal error for the Zip extension.

Before this fix, creating a new application throws a fatal error if the Zip extension is not installed.
parent 3b74dda6
......@@ -37,6 +37,10 @@ class NewCommand extends Command
*/
protected function execute(InputInterface $input, OutputInterface $output)
{
if (! class_exists('ZipArchive')) {
throw new RuntimeException('The Zip extension is missing on your system. Please install it and try again.');
}
$this->verifyApplicationDoesntExist(
$directory = getcwd().'/'.$input->getArgument('name'),
$output
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment