X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fdrupal%2Fconsole%2Fsrc%2FCommand%2FGenerate%2FServiceCommand.php;h=8106f152328eb10e6d88544eb0e47bc1a3debf97;hp=e71edc113674b275b0427ce98387132a0602c6f1;hb=eba34333e3c89f208d2f72fa91351ad019a71583;hpb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae diff --git a/vendor/drupal/console/src/Command/Generate/ServiceCommand.php b/vendor/drupal/console/src/Command/Generate/ServiceCommand.php index e71edc113..8106f1523 100644 --- a/vendor/drupal/console/src/Command/Generate/ServiceCommand.php +++ b/vendor/drupal/console/src/Command/Generate/ServiceCommand.php @@ -104,13 +104,13 @@ class ServiceCommand extends Command ) ->addOption( 'interface', - false, + null, InputOption::VALUE_NONE, $this->trans('commands.common.service.options.interface') ) ->addOption( 'interface_name', - false, + null, InputOption::VALUE_OPTIONAL, $this->trans('commands.common.service.options.interface_name') ) @@ -137,7 +137,7 @@ class ServiceCommand extends Command // @see use Drupal\Console\Command\Shared\ConfirmationTrait::confirmGeneration if (!$this->confirmGeneration($io)) { - return; + return 1; } $module = $input->getOption('module'); @@ -164,6 +164,8 @@ class ServiceCommand extends Command $this->generator->generate($module, $name, $class, $interface, $interface_name, $build_services, $path_service); $this->chainQueue->addCommand('cache:rebuild', ['cache' => 'all']); + + return 0; } /**