Test Setup Failed
Branch master (84a300)
by Serhii
17:22
created
Category
src/GSCPDownloadTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@
 block discarded – undo
7 7
 
8 8
     private function download(): void
9 9
     {
10
-        if(!file_exists($this->filename)) {
10
+        if (!file_exists($this->filename)) {
11 11
             $url = str_replace('%locale%', $this->getLocale(), $this->url);
12 12
             copy($url, $this->filename);
13 13
         }
Please login to merge, or discard this patch.
src/GSCPService.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -65,15 +65,15 @@  discard block
 block discarded – undo
65 65
     private function parse(): void
66 66
     {
67 67
         $parsedCategories = [];
68
-        for ($depth=0; $depth<self::DEPTH; $depth++) {
68
+        for ($depth = 0; $depth < self::DEPTH; $depth++) {
69 69
             foreach ($this->categories as $id => $category) {
70
-                if(count($category) !== $depth + 1) {
70
+                if (count($category) !== $depth + 1) {
71 71
                     continue;
72 72
                 }
73 73
 
74 74
                 $parentId = 0;
75
-                $parentCategoryDepth = $depth-1;
76
-                if($parentCategoryDepth >= 0) {
75
+                $parentCategoryDepth = $depth - 1;
76
+                if ($parentCategoryDepth >= 0) {
77 77
                     foreach ($parsedCategories as $item) {
78 78
                         if ($item['name'] === $category[$parentCategoryDepth]) {
79 79
                             $parentId = $item['id'];
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
                 $parentId = $this->categories[$parentId]['parentId'];
122 122
             }
123 123
 
124
-            $item['parents'] =  $parents;
124
+            $item['parents'] = $parents;
125 125
         }
126 126
     }
127 127
 
Please login to merge, or discard this patch.