Commit ede6c279 authored by Taylor Otwell's avatar Taylor Otwell

Merge pull request #46 from saulotoledo/master

Throw an exception instead of a fatal error for the Zip extension.
parents 3b74dda6 ac0e2306
...@@ -37,6 +37,10 @@ class NewCommand extends Command ...@@ -37,6 +37,10 @@ class NewCommand extends Command
*/ */
protected function execute(InputInterface $input, OutputInterface $output) 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( $this->verifyApplicationDoesntExist(
$directory = getcwd().'/'.$input->getArgument('name'), $directory = getcwd().'/'.$input->getArgument('name'),
$output $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