Total Complexity | 9 |
Total Lines | 49 |
Duplicated Lines | 0 % |
Coverage | 80.77% |
Changes | 0 |
1 | <?php |
||
8 | class VersioneExtension extends \Twig_Extension |
||
9 | { |
||
10 | private $projectpath; |
||
11 | |||
12 | 26 | public function __construct($projectpath) |
|
13 | { |
||
14 | 26 | $this->projectpath = $projectpath; |
|
15 | 26 | } |
|
16 | |||
17 | public function getFunctions() |
||
18 | { |
||
19 | return array( |
||
20 | new \Twig_SimpleFunction('versione_tag_git', array($this, 'versioneTagGit', 'is_safe' => array('html'))), |
||
21 | ); |
||
22 | } |
||
23 | |||
24 | 12 | public function versioneTagGit() |
|
49 | } |
||
50 | |||
51 | 12 | private function isWindows() |
|
60 |
This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.
To visualize
will produce issues in the first and second line, while this second example
will produce no issues.