composer require lock doesn't resolve the lock alias because the package name resolution is skipped when the package argument is lock. This PR bypasses this specifically for the require command, so that composer require lock correctly resolved the alias, but composer update lock still skips the name resolution.
composer require lock
doesn't resolve thelock
alias because the package name resolution is skipped when the package argument islock
. This PR bypasses this specifically for therequire
command, so thatcomposer require lock
correctly resolved the alias, butcomposer update lock
still skips the name resolution.Reference: https://github.com/symfony/recipes/issues/1150