1 | <?php |
||
21 | abstract class AbstractFileGenerator |
||
22 | { |
||
23 | /** |
||
24 | * [$currentFile description] |
||
25 | * |
||
26 | * @var [type] |
||
27 | */ |
||
28 | protected $currentFile; |
||
29 | |||
30 | /** |
||
31 | * Array process errors |
||
32 | * |
||
33 | * @var array |
||
34 | */ |
||
35 | protected $errors; |
||
36 | |||
37 | /** |
||
38 | * [$logger description] |
||
39 | * |
||
40 | * @var \Psr\Log\LoggerInterface |
||
41 | */ |
||
42 | protected $logger; |
||
43 | |||
44 | public function setLogger(LoggerInterface $logger) |
||
48 | |||
49 | protected function error($message, $context = []) |
||
55 | |||
56 | protected function info($message, $context = []) |
||
62 | |||
63 | /** |
||
64 | * errori durante la generazione |
||
65 | * |
||
66 | * @return array of string |
||
67 | */ |
||
68 | public function getErrors() |
||
72 | |||
73 | public function toString() |
||
77 | |||
78 | protected function _createFileOnDir(Local $adapter, $outFile) |
||
96 | } |
||
97 |
Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.
The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.
This check looks for comments that seem to be mostly valid code and reports them.