@@ -45,13 +45,15 @@ class Plugin implements PluginInterface, EventSubscriberInterface
45
45
*/
46
46
private const PROVIDE_RULES = [
47
47
'php-http/async-client-implementation ' => [
48
+ 'symfony/http-client:>=6.3 ' => ['guzzlehttp/promises ' , 'psr/http-factory-implementation ' ],
48
49
'symfony/http-client ' => ['guzzlehttp/promises ' , 'php-http/message-factory ' , 'psr/http-factory-implementation ' ],
49
50
'php-http/guzzle7-adapter ' => [],
50
51
'php-http/guzzle6-adapter ' => [],
51
52
'php-http/curl-client ' => [],
52
53
'php-http/react-adapter ' => [],
53
54
],
54
55
'php-http/client-implementation ' => [
56
+ 'symfony/http-client:>=6.3 ' => ['psr/http-factory-implementation ' ],
55
57
'symfony/http-client ' => ['php-http/message-factory ' , 'psr/http-factory-implementation ' ],
56
58
'php-http/guzzle7-adapter ' => [],
57
59
'php-http/guzzle6-adapter ' => [],
@@ -332,22 +334,12 @@ public function getMissingRequires(InstalledRepositoryInterface $repo, array $re
332
334
}
333
335
334
336
$ dep = key ($ candidates );
337
+ [$ dep ] = explode (': ' , $ dep , 2 );
335
338
$ missingRequires [$ dev ][$ abstraction ] = [$ dep ];
336
339
337
340
if ($ isProject && !$ dev && isset ($ devPackages [$ dep ])) {
338
341
$ missingRequires [2 ][$ abstraction ][] = $ dep ;
339
342
}
340
-
341
- foreach (current ($ candidates ) as $ dep ) {
342
- if (isset (self ::PROVIDE_RULES [$ dep ])) {
343
- $ abstractions [] = $ dep ;
344
- } elseif (!isset ($ allPackages [$ dep ])) {
345
- $ missingRequires [$ dev ][$ abstraction ][] = $ dep ;
346
- } elseif ($ isProject && !$ dev && isset ($ devPackages [$ dep ])) {
347
- $ missingRequires [0 ][$ abstraction ][] = $ dep ;
348
- $ missingRequires [2 ][$ abstraction ][] = $ dep ;
349
- }
350
- }
351
343
}
352
344
}
353
345
0 commit comments