Completed
Pull Request — master (#122)
by Matthias
01:39
created
src/Processes/ChurnProcess.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
      */
71 71
     public function getKey(): string
72 72
     {
73
-        return $this->getType() . $this->file->getFullPath();
73
+        return $this->getType().$this->file->getFullPath();
74 74
     }
75 75
 
76 76
     /**
Please login to merge, or discard this patch.
src/Results/ResultsParser.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
     {
61 61
         $output = $process->getOutput();
62 62
         preg_match("/([0-9]{1,})/", $output, $matches);
63
-        if (! isset($matches[1])) {
63
+        if (!isset($matches[1])) {
64 64
             return 0;
65 65
         }
66 66
         return (integer) $matches[1];
Please login to merge, or discard this patch.
src/Factories/ProcessFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
     public function createGitCommitProcess(File $file): ChurnProcess
27 27
     {
28 28
         $process = new Process(
29
-            'git -C ' . getcwd() . " log --since=\"" . $this->config->getCommitsSince() . "\"  --name-only --pretty=format: " . $file->getFullPath(). " | sort | uniq -c | sort -nr"
29
+            'git -C '.getcwd()." log --since=\"".$this->config->getCommitsSince()."\"  --name-only --pretty=format: ".$file->getFullPath()." | sort | uniq -c | sort -nr"
30 30
         );
31 31
 
32 32
         return new ChurnProcess($file, $process, 'GitCommitProcess');
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
      */
40 40
     public function createCyclomaticComplexityProcess(File $file): ChurnProcess
41 41
     {
42
-        $rootFolder = __DIR__ . '/../../';
42
+        $rootFolder = __DIR__.'/../../';
43 43
 
44 44
         $process = new Process(
45 45
             "php {$rootFolder}CyclomaticComplexityAssessorRunner {$file->getFullPath()}"
Please login to merge, or discard this patch.
src/Managers/FileManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
     {
54 54
         $directoryIterator = new RecursiveDirectoryIterator($path);
55 55
         foreach (new RecursiveIteratorIterator($directoryIterator) as $file) {
56
-            if (! in_array($file->getExtension(), $this->fileExtensions)) {
56
+            if (!in_array($file->getExtension(), $this->fileExtensions)) {
57 57
                 continue;
58 58
             }
59 59
 
Please login to merge, or discard this patch.
bootstrap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 
3 3
 if (is_file($autoload = __DIR__.'/vendor/autoload.php')) {
4 4
     require_once($autoload);
5
-} elseif (is_file($autoload = __DIR__ . '/../../autoload.php')) {
5
+} elseif (is_file($autoload = __DIR__.'/../../autoload.php')) {
6 6
     require_once($autoload);
7 7
 } else {
8 8
     fwrite(STDERR,
Please login to merge, or discard this patch.
src/Results/ResultCollection.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace Churn\Results;
4 4
 
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
      */
14 14
     public function orderByScoreDesc(): self
15 15
     {
16
-        return $this->sortByDesc(function (Result $result) {
16
+        return $this->sortByDesc(function(Result $result) {
17 17
             return $result->getScore($this->maxCommits(), $this->maxComplexity());
18 18
         });
19 19
     }
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 
30 30
         return $this->orderByScoreDesc()
31 31
             ->filter(
32
-                function (Result $result) use ($minScore) {
32
+                function(Result $result) use ($minScore) {
33 33
                     return $result->getScore($this->maxCommits(), $this->maxComplexity()) >= $minScore;
34 34
                 }
35 35
             )
@@ -38,14 +38,14 @@  discard block
 block discarded – undo
38 38
 
39 39
     public function maxCommits(): int
40 40
     {
41
-        return $this->max(function (Result $result) {
41
+        return $this->max(function(Result $result) {
42 42
             return $result->getCommits();
43 43
         });
44 44
     }
45 45
 
46 46
     public function maxComplexity(): int
47 47
     {
48
-        return $this->max(function (Result $result) {
48
+        return $this->max(function(Result $result) {
49 49
             return $result->getComplexity();
50 50
         });
51 51
     }
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     public function toArray(): array
59 59
     {
60 60
         return array_values(array_map(
61
-            function (Result $result) {
61
+            function(Result $result) {
62 62
                 return array_merge(
63 63
                     $result->toArray(),
64 64
                     [$result->getScore($this->maxCommits(), $this->maxComplexity())]
Please login to merge, or discard this patch.