1
0
Fork 0

Fix param nullability

pull/10656/head
Jordi Boggiano 2022-03-21 14:00:37 +01:00
parent 8b373a1306
commit 166542f981
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC
2 changed files with 11 additions and 1 deletions

View File

@ -4260,6 +4260,16 @@ parameters:
count: 2 count: 2
path: ../src/Composer/Repository/PathRepository.php path: ../src/Composer/Repository/PathRepository.php
-
message: "#^Constructor of class Composer\\\\Repository\\\\PathRepository has an unused parameter \\$dispatcher\\.$#"
count: 1
path: ../src/Composer/Repository/PathRepository.php
-
message: "#^Constructor of class Composer\\\\Repository\\\\PathRepository has an unused parameter \\$httpDownloader\\.$#"
count: 1
path: ../src/Composer/Repository/PathRepository.php
- -
message: "#^Only booleans are allowed in &&, string\\|false given on the right side\\.$#" message: "#^Only booleans are allowed in &&, string\\|false given on the right side\\.$#"
count: 1 count: 1

View File

@ -111,7 +111,7 @@ class PathRepository extends ArrayRepository implements ConfigurableRepositoryIn
* @param IOInterface $io * @param IOInterface $io
* @param Config $config * @param Config $config
*/ */
public function __construct(array $repoConfig, IOInterface $io, Config $config, HttpDownloader $httpDownloader, EventDispatcher $dispatcher = null, ProcessExecutor $process = null) public function __construct(array $repoConfig, IOInterface $io, Config $config, HttpDownloader $httpDownloader = null, EventDispatcher $dispatcher = null, ProcessExecutor $process = null)
{ {
if (!isset($repoConfig['url'])) { if (!isset($repoConfig['url'])) {
throw new \RuntimeException('You must specify the `url` configuration for the path repository'); throw new \RuntimeException('You must specify the `url` configuration for the path repository');