Completed
Pull Request — master (#504)
by
unknown
30s
created
templates/html_report/loc.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 use Hal\Report\Html\ViewHelper;
4 4
 
5
-require __DIR__ . '/_header.php';
5
+require __DIR__.'/_header.php';
6 6
 /** @var ViewHelper $viewHelper */
7 7
 $viewHelper = $this->viewHelper;
8 8
 
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
     sort($logicalLinesOfCodeByClass);
19 19
     $range = range(0.5, 1, .05);
20 20
     foreach ($range as $percentile) {
21
-        $json[] = (object)[
21
+        $json[] = (object) [
22 22
             'lloc' => $logicalLinesOfCodeByClass[max(round($percentile * ($nbStats - 1) - 1), 0)],
23 23
             'percentile' => round($percentile * 100),
24 24
         ];
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
                         <td><span class="path"><?php echo $class['name']; ?></span></td>
60 60
                         <?php foreach (['lloc', 'cloc', 'volume', 'intelligentContent', 'commentWeight'] as $attribute) {?>
61 61
                             <td>
62
-                                <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]);?>>
62
+                                <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]); ?>>
63 63
                                 <?php echo isset($class[$attribute]) ? $class[$attribute] : ''; ?>
64 64
                                 </span>
65 65
                             </td>
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 </div>
73 73
 
74 74
 
75
-<?php require __DIR__ . '/_footer.php'; ?>
75
+<?php require __DIR__.'/_footer.php'; ?>
76 76
 
77 77
 
78 78
 <script>
Please login to merge, or discard this patch.
templates/html_report/complexity.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@
 block discarded – undo
75 75
                     <tbody>
76 76
                     <?php
77 77
                     foreach ($this->sharedMetrics->classes as $class) {
78
-                      $classHash = md5($class['name']);
78
+                        $classHash = md5($class['name']);
79 79
                     ?>
80 80
                         <tr>
81 81
                             <td>
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 use Hal\Report\Html\ViewHelper;
4 4
 
5
-require __DIR__ . '/_header.php';
5
+require __DIR__.'/_header.php';
6 6
 /** @var ViewHelper $viewHelper */
7 7
 $viewHelper = $this->viewHelper;
8 8
 ?>
@@ -93,12 +93,12 @@  discard block
 block discarded – undo
93 93
                                   <?php foreach ($class['methods'] as $method) { ?>
94 94
                                     <?php if ($method->get('isAccessor')) { ?>
95 95
                                     <tr>
96
-                                      <td><span class="path ignored"><?php echo $class['name'] . '::' . $method->getName(); ?></span> <small>(accessors are ignored)</small></td>
96
+                                      <td><span class="path ignored"><?php echo $class['name'].'::'.$method->getName(); ?></span> <small>(accessors are ignored)</small></td>
97 97
                                       <td><span>-</span></td>
98 98
                                     </tr>
99 99
                                     <?php } else { ?>
100 100
                                     <tr>
101
-                                      <td><span class="path"><?php echo $class['name'] . '::' . $method->getName(); ?></span></td>
101
+                                      <td><span class="path"><?php echo $class['name'].'::'.$method->getName(); ?></span></td>
102 102
                                       <td><span><?php echo $method->get('ccn'); ?></span></td>
103 103
                                     </tr>
104 104
                                   <?php } ?>
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
                             </td>
113 113
                             <?php foreach (['wmc', 'ccn', 'ccnMethodMax', 'relativeSystemComplexity', 'relativeDataComplexity', 'relativeStructuralComplexity', 'bugs', 'kanDefect'] as $attribute) {?>
114 114
                                 <td>
115
-                                    <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]);?>>
115
+                                    <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]); ?>>
116 116
                                     <?php echo $class[$attribute] ?? ''; ?>
117 117
                                     </span>
118 118
                                 </td>
@@ -126,4 +126,4 @@  discard block
 block discarded – undo
126 126
     </div>
127 127
 
128 128
 
129
-<?php require __DIR__ . '/_footer.php'; ?>
129
+<?php require __DIR__.'/_footer.php'; ?>
Please login to merge, or discard this patch.
templates/html_report/relations.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,17 +1,17 @@  discard block
 block discarded – undo
1
-<?php require __DIR__ . '/_header.php'; ?>
1
+<?php require __DIR__.'/_header.php'; ?>
2 2
 
3 3
 <?php
4 4
 $relations = [];
5 5
 $classesCp = [];
6 6
 foreach ($this->sharedMetrics->classes as $class) {
7 7
 
8
-    $class['name'] = '\\' . $class['name'];
8
+    $class['name'] = '\\'.$class['name'];
9 9
     $classesCp[$class['name']] = $class;
10 10
     $classesCp[$class['name']]['externals'] = [];
11 11
 
12 12
 
13 13
     foreach ($class['externals'] as &$ext) {
14
-        $ext = '\\' . $ext;
14
+        $ext = '\\'.$ext;
15 15
         if (!isset($this->sharedMetrics->classes[$ext])) {
16 16
             $classesCp[$ext] = [
17 17
                 'name' => $ext,
@@ -22,10 +22,10 @@  discard block
 block discarded – undo
22 22
     }
23 23
 }
24 24
 foreach ($classesCp as $class) {
25
-    array_push($relations, (object)[
25
+    array_push($relations, (object) [
26 26
         'name' => $class['name'],
27 27
         'size' => 3000,
28
-        'relations' => (array)array_values(array_unique($class['externals'])),
28
+        'relations' => (array) array_values(array_unique($class['externals'])),
29 29
     ]);
30 30
 }
31 31
 ?>
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
     </div>
41 41
 </div>
42 42
 
43
-<?php require __DIR__ . '/_footer.php'; ?>
43
+<?php require __DIR__.'/_footer.php'; ?>
44 44
 
45 45
 
46 46
 <script>
Please login to merge, or discard this patch.
templates/html_report/panel.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 $fullwidth = true;
3
-require __DIR__ . '/_header.php'; ?>
3
+require __DIR__.'/_header.php'; ?>
4 4
 
5 5
     <div class="row">
6 6
         <div class="column">
@@ -96,4 +96,4 @@  discard block
 block discarded – undo
96 96
     </script>
97 97
 
98 98
 <?php
99
-require __DIR__ . '/_footer.php'; ?>
99
+require __DIR__.'/_footer.php'; ?>
Please login to merge, or discard this patch.
templates/html_report/oop.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 use Hal\Report\Html\ViewHelper;
4 4
 
5
-require __DIR__ . '/_header.php';
5
+require __DIR__.'/_header.php';
6 6
 /** @var ViewHelper $viewHelper */
7 7
 $viewHelper = $this->viewHelper;
8 8
 
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
                             <td><span class="path"><?php echo $class['name']; ?></span></td>
81 81
                             <?php foreach (['lcom', 'volume', 'ccn', 'ccnMethodMax', 'bugs', 'difficulty'] as $attribute) {?>
82 82
                                 <td>
83
-                                    <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]);?>>
83
+                                    <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]); ?>>
84 84
                                     <?php echo isset($class[$attribute]) ? $class[$attribute] : ''; ?>
85 85
                                     </span>
86 86
                                 </td>
@@ -93,4 +93,4 @@  discard block
 block discarded – undo
93 93
     </div>
94 94
 
95 95
 
96
-<?php require __DIR__ . '/_footer.php'; ?>
96
+<?php require __DIR__.'/_footer.php'; ?>
Please login to merge, or discard this patch.
templates/html_report/violations.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php require __DIR__ . '/_header.php'; ?>
1
+<?php require __DIR__.'/_header.php'; ?>
2 2
 
3 3
 <?php
4 4
 $map = [
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
                     <tbody>
58 58
                     <?php foreach ($this->sharedMetrics->classes as $class) {
59 59
                         if (count($class['violations']) > 0) {
60
-                            $currentId = 'bloc-' . uniqid('', true);
60
+                            $currentId = 'bloc-'.uniqid('', true);
61 61
                             ?>
62 62
 
63 63
                             <tr>
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
                     <tbody>
111 111
                     <?php foreach ($this->sharedMetrics->packages as $package) {
112 112
                         if (count($package['violations']) > 0) {
113
-                            $currentId = 'bloc-' . uniqid();
113
+                            $currentId = 'bloc-'.uniqid();
114 114
                             ?>
115 115
 
116 116
                             <tr>
@@ -162,4 +162,4 @@  discard block
 block discarded – undo
162 162
             }
163 163
         }
164 164
     </script>
165
-<?php require __DIR__ . '/_footer.php'; ?>
165
+<?php require __DIR__.'/_footer.php'; ?>
Please login to merge, or discard this patch.
templates/html_report/_header.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -62,10 +62,10 @@
 block discarded – undo
62 62
         <?php if ([] !== $this->groups) {?>
63 63
         <div class="content-full group-tabs">
64 64
             <ul class="tabs">
65
-                <li class="<?php if(!$this->currentGroup) { echo 'active'; }?>"><a href="<?php echo $this->assetPath;?>index.html">All</a></li>
65
+                <li class="<?php if (!$this->currentGroup) { echo 'active'; }?>"><a href="<?php echo $this->assetPath; ?>index.html">All</a></li>
66 66
                 <?php foreach ($this->groups as $group) { ?>
67 67
                     <li class="<?php if ($group->name === $this->currentGroup) { echo 'active'; }?> ">
68
-                        <a href="<?php echo $this->assetPath . $group->name;?>/index.html"><?php echo $group->name;?></a>
68
+                        <a href="<?php echo $this->assetPath.$group->name; ?>/index.html"><?php echo $group->name; ?></a>
69 69
                     </li>
70 70
                 <?php } ?>
71 71
             </ul>
Please login to merge, or discard this patch.
templates/html_report/composer.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,13 +1,13 @@  discard block
 block discarded – undo
1 1
 <?php
2
-require __DIR__ . '/_header.php';
2
+require __DIR__.'/_header.php';
3 3
 
4 4
 $packages = isset($this->sharedMetrics->project['composer']['packages']) ? $this->sharedMetrics->project['composer']['packages'] : [];
5
-usort($packages, function ($a, $b) {
5
+usort($packages, function($a, $b) {
6 6
     return strcmp($a->name, $b->name);
7 7
 });
8 8
 if ([] === $packages) {
9 9
     echo '<div class="row"><div class="column"><div class="bloc">No composer.json file found in this project</div></div></div>';
10
-    require __DIR__ . '/_footer.php';
10
+    require __DIR__.'/_footer.php';
11 11
     return;
12 12
 }
13 13
 ?>
@@ -97,4 +97,4 @@  discard block
 block discarded – undo
97 97
     </div>
98 98
 </div>
99 99
 
100
-<?php require __DIR__ . '/_footer.php'; ?>
100
+<?php require __DIR__.'/_footer.php'; ?>
Please login to merge, or discard this patch.
templates/html_report/coupling.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 use Hal\Report\Html\ViewHelper;
4 4
 
5
-require __DIR__ . '/_header.php';
5
+require __DIR__.'/_header.php';
6 6
 /** @var ViewHelper $viewHelper */
7 7
 $viewHelper = $this->viewHelper;
8 8
 ?>
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
                         <td><span class="path"><?php echo $class['name']; ?></span></td>
33 33
                         <?php foreach (['afferentCoupling', 'efferentCoupling', 'instability'] as $attribute) {?>
34 34
                             <td>
35
-                                <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]);?>>
35
+                                <span class="badge" <?php echo $viewHelper->gradientStyleFor($this->sharedMetrics->classes, $attribute, $class[$attribute]); ?>>
36 36
                                 <?php echo isset($class[$attribute]) ? $class[$attribute] : ''; ?>
37 37
                                 </span>
38 38
                             </td>
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 
48 48
 </div>
49 49
 
50
-<?php require __DIR__ . '/_footer.php'; ?>
50
+<?php require __DIR__.'/_footer.php'; ?>
51 51
 
52 52
 
53 53
 <script>
Please login to merge, or discard this patch.