Passed
Push — master ( e10e66...c0e1ba )
by Nicolas
04:25
created
src/Manager.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -53,11 +53,11 @@  discard block
 block discarded – undo
53 53
      */
54 54
     public function files()
55 55
     {
56
-        $files = Collection::make($this->disk->allFiles($this->path))->filter(function ($file) {
56
+        $files = Collection::make($this->disk->allFiles($this->path))->filter(function($file) {
57 57
             return $this->disk->extension($file) == 'php';
58 58
         });
59 59
 
60
-        $filesByFile = $files->groupBy(function ($file) {
60
+        $filesByFile = $files->groupBy(function($file) {
61 61
             $filePath = str_replace('.'.$file->getExtension(), '', $file->getRelativePathname());
62 62
             $filePath = array_reverse(explode('/', $filePath, 2))[0];
63 63
 
@@ -70,10 +70,10 @@  discard block
 block discarded – undo
70 70
             } else {
71 71
                 return $filePath;
72 72
             }
73
-        })->map(function ($files) {
74
-            return $files->keyBy(function ($file) {
73
+        })->map(function($files) {
74
+            return $files->keyBy(function($file) {
75 75
                 return explode('/', str_replace($this->path, '', $file->getRelativePathname()))[0];
76
-            })->map(function ($file) {
76
+            })->map(function($file) {
77 77
                 return $file->getRealPath();
78 78
             });
79 79
         });
@@ -119,11 +119,11 @@  discard block
 block discarded – undo
119 119
      */
120 120
     public function languages()
121 121
     {
122
-        $languages = array_map(function ($directory) {
122
+        $languages = array_map(function($directory) {
123 123
             return basename($directory);
124 124
         }, $this->disk->directories($this->path));
125 125
 
126
-        $languages = array_filter($languages, function ($directory) {
126
+        $languages = array_filter($languages, function($directory) {
127 127
             return $directory != 'vendor' && $directory != 'json';
128 128
         });
129 129
 
@@ -323,8 +323,8 @@  discard block
 block discarded – undo
323 323
 
324 324
         $pattern =
325 325
             // See https://regex101.com/r/jS5fX0/4
326
-            '[^\w]'. // Must not start with any alphanum or _
327
-            '(?<!->)'. // Must not start with ->
326
+            '[^\w]'.// Must not start with any alphanum or _
327
+            '(?<!->)'.// Must not start with ->
328 328
             '('.implode('|', $functions).')'.// Must start with one of the functions
329 329
             "\(".// Match opening parentheses
330 330
             "[\'\"]".// Match " or '
@@ -333,7 +333,7 @@  discard block
 block discarded – undo
333 333
             "([.][^\1)$]+)+".// Be followed by one or more items/keys
334 334
             ')'.// Close group
335 335
             "[\'\"]".// Closing quote
336
-            "[\),]";  // Close parentheses or new parameter
336
+            "[\),]"; // Close parentheses or new parameter
337 337
 
338 338
         $allMatches = [];
339 339
 
Please login to merge, or discard this patch.