Skip to content

Commit 0f6ce75

Browse files
Allow command description to be dynamically set depending on what name is given to the command (#8)
Co-authored-by: jonnywilliamson <[email protected]>
1 parent b81033a commit 0f6ce75

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Console/Command/CommandListCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ protected function getCommandsList(): array
4646

4747
return collect($handler->getCommands())
4848
->map(
49-
fn ($command, $name): array => [$name, $handler->getCommandBus()->resolveCommand($command)->getDescription()]
49+
fn ($command, $name): array => [$name, $handler->getCommandBus()->resolveCommand($command)->setName($name)->getDescription()]
5050
)->all();
5151
}
5252
}

0 commit comments

Comments
 (0)