Conditions | 2 |
Paths | 2 |
Total Lines | 17 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
30 | public function __invoke($namespace) |
||
31 | { |
||
32 | $composerConfig = $this->getComposerConfig($namespace); |
||
33 | $config = new Config(); |
||
34 | |||
35 | $config->diff = Get\value('diff', $composerConfig, false); |
||
36 | $config->{'dry-run'} = Get\value('dry-run', $composerConfig, false); |
||
37 | $config->setUsingCache(Get\value('cache', $composerConfig, false)); |
||
38 | |||
39 | $path = Get\value('path', $composerConfig); |
||
40 | if (!empty($path)) { |
||
41 | $finderByConfig = new FinderByConfig(); |
||
42 | $config->setFinder($finderByConfig($path)); |
||
43 | } |
||
44 | |||
45 | return $config; |
||
46 | } |
||
47 | } |
||
48 |