Conditions | 3 |
Paths | 3 |
Total Lines | 11 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 12 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
18 | public function createFixersFromFiles(array $files) : array |
||
19 | { |
||
20 | $fixers = []; |
||
21 | foreach ($files as $file) { |
||
22 | $relativeNamespace = $file->getRelativePath(); |
||
|
|||
23 | $class = 'Symfony\\CS\\Fixer\\' . ($relativeNamespace ? $relativeNamespace . '\\' : '') . $file->getBasename('.php'); |
||
24 | $fixers[] = new $class; |
||
25 | } |
||
26 | |||
27 | return $fixers; |
||
28 | } |
||
29 | } |
||
30 |
Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.