This class seems to be duplicated in your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate
the same code in three or more different places, we strongly encourage you to
look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.
Loading history...
16
{
17
/**
18
* Command action.
19
*
20
* @var string
21
*/
22
protected $action;
23
24
/**
25
* Option list.
26
*
27
* @var string[]
28
*/
29
protected $options = [];
30
31
/**
32
* Package list.
33
*
34
* @var string[]
35
*/
36
protected $packages = [];
37
38
/**
39
* {@inheritdoc}
40
*/
41
5
public function install(array $packages)
42
{
43
5
if (empty($packages)) {
44
1
throw new \Exception('No packages selected to be installed');
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.