Skip to content

Commit

Permalink
[console] Read alias as array. (#2920)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmolivas authored Nov 12, 2016
1 parent 177705e commit 555fd3c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,10 @@ private function registerCommands()

if (array_key_exists($command->getName(), $aliases)) {
$commandAliases = $aliases[$command->getName()];
$command->setAliases([$commandAliases]);
if (!is_array($commandAliases)) {
$commandAliases = [$commandAliases];
}
$command->setAliases($commandAliases);
}

$this->add($command);
Expand Down

0 comments on commit 555fd3c

Please sign in to comment.