Skip to content

Commit

Permalink
Fix showing a single package by name in show command, fixes #10623
Browse files Browse the repository at this point in the history
  • Loading branch information
Seldaek committed Mar 16, 2022
1 parent d955458 commit a2bdf72
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Composer/Command/ShowCommand.php
Expand Up @@ -255,7 +255,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
// show single package or single version
if (isset($package)) {
$versions = array($package->getPrettyVersion() => $package->getVersion());
} elseif (null !== $packageFilter && str_contains($packageFilter, '*')) {
} elseif (null !== $packageFilter && !str_contains($packageFilter, '*')) {
list($package, $versions) = $this->getPackage($installedRepo, $repos, $packageFilter, $input->getArgument('version'));

if (!isset($package)) {
Expand Down

0 comments on commit a2bdf72

Please sign in to comment.