Passed
Push — master ( 1e7a46...432690 )
by Hong
03:11
created
src/Util/Loader.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -104,11 +104,11 @@
 block discarded – undo
104 104
     }
105 105
 
106 106
     /**
107
-      * Returns an array of directoris to search thru
108
-      *
109
-      * @param  string $environment
110
-      * @return array
111
-      */
107
+     * Returns an array of directoris to search thru
108
+     *
109
+     * @param  string $environment
110
+     * @return array
111
+     */
112 112
     protected function searchDirs(string $environment): array
113 113
     {
114 114
         $envs  = preg_split(
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
     public function load(string $group = '', string $environment = ''): object
73 73
     {
74 74
         foreach ($this->globFiles($group, $environment) as $file) {
75
-            $grp  = explode('.', basename($file), 2)[0];
75
+            $grp = explode('.', basename($file), 2)[0];
76 76
             $this->tree->add($grp, $this->reader->readFile($file));
77 77
         }
78 78
         return $this;
@@ -96,9 +96,9 @@  discard block
 block discarded – undo
96 96
     protected function globFiles(string $group, string $environment): array
97 97
     {
98 98
         $files = [];
99
-        $grp = ($group ?: '*') . '.*';
99
+        $grp = ($group ?: '*').'.*';
100 100
         foreach ($this->searchDirs($environment) as $dir) {
101
-            $files = array_merge($files, glob($dir . \DIRECTORY_SEPARATOR . $grp));
101
+            $files = array_merge($files, glob($dir.\DIRECTORY_SEPARATOR.$grp));
102 102
         }
103 103
         return $files;
104 104
     }
@@ -111,17 +111,17 @@  discard block
 block discarded – undo
111 111
       */
112 112
     protected function searchDirs(string $environment): array
113 113
     {
114
-        $envs  = preg_split(
114
+        $envs = preg_split(
115 115
             '~/~',
116 116
             trim($environment ?: $this->environment, '/'),
117 117
             -1,
118 118
             \PREG_SPLIT_NO_EMPTY
119 119
         );
120 120
 
121
-        $d  = $this->root_dir;
121
+        $d = $this->root_dir;
122 122
         $dirs[] = $d;
123 123
         foreach ($envs as $p) {
124
-            $d .= \DIRECTORY_SEPARATOR . $p;
124
+            $d .= \DIRECTORY_SEPARATOR.$p;
125 125
             $dirs[] = $d;
126 126
         }
127 127
         return $dirs;
Please login to merge, or discard this patch.