Skip to content

Commit

Permalink
[generate:command] Replace null with empty string as default value on…
Browse files Browse the repository at this point in the history
… choiceNoList. (#3728)
  • Loading branch information
jmolivas authored Jan 22, 2018
1 parent 6523926 commit c1c7deb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Command/Shared/ServicesTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,17 @@ public function servicesQuestion()
$service_collection = [];
$this->getIo()->writeln($this->trans('commands.common.questions.services.message'));
$services = $this->container->getServiceIds();

while (true) {
$service = $this->getIo()->choiceNoList(
$this->trans('commands.common.questions.services.name'),
$services,
null,
'',
true
);

$service = trim($service);
if (empty($service)) {
if (empty($service) || is_numeric($service)) {
break;
}

Expand Down

0 comments on commit c1c7deb

Please sign in to comment.