Completed
Push — master ( 093ab2...84b6a3 )
by John
01:55
created
src/Request/MIMEFileProvider.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -13,21 +13,21 @@
 block discarded – undo
13 13
 
14 14
     //Borrowed from http://stackoverflow.com/a/1147952
15 15
     public function getAll(): array {
16
-        if($this->cache){
16
+        if ($this->cache) {
17 17
             return $this->cache;
18 18
         }
19 19
 
20 20
         # Returns the system MIME type mapping of extensions to MIME types, as defined in /etc/mime.types.
21 21
         $out = array();
22
-        while(($line = fgets($this->file)) !== false) {
22
+        while (($line = fgets($this->file)) !== false) {
23 23
             $line = trim(preg_replace('/#.*/', '', $line));
24
-            if(!$line)
24
+            if (!$line)
25 25
                 continue;
26 26
             $parts = preg_split('/\s+/', $line);
27
-            if(count($parts) == 1)
27
+            if (count($parts) == 1)
28 28
                 continue;
29 29
             $type = array_shift($parts);
30
-            foreach($parts as $part)
30
+            foreach ($parts as $part)
31 31
                 $out[$part] = $type;
32 32
         }
33 33
 
Please login to merge, or discard this patch.
Braces   +9 added lines, -6 removed lines patch added patch discarded remove patch
@@ -21,14 +21,17 @@
 block discarded – undo
21 21
         $out = array();
22 22
         while(($line = fgets($this->file)) !== false) {
23 23
             $line = trim(preg_replace('/#.*/', '', $line));
24
-            if(!$line)
25
-                continue;
24
+            if(!$line) {
25
+                            continue;
26
+            }
26 27
             $parts = preg_split('/\s+/', $line);
27
-            if(count($parts) == 1)
28
-                continue;
28
+            if(count($parts) == 1) {
29
+                            continue;
30
+            }
29 31
             $type = array_shift($parts);
30
-            foreach($parts as $part)
31
-                $out[$part] = $type;
32
+            foreach($parts as $part) {
33
+                            $out[$part] = $type;
34
+            }
32 35
         }
33 36
 
34 37
         $this->cache = $out;
Please login to merge, or discard this patch.