Completed
Push — 4.0 ( 0fc1f3...2aa397 )
by Marco
02:59
created
src/Comodojo/Dispatcher/Request/File.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
     public function getLocalName() {
63 63
 
64 64
         if (!empty($this->path))
65
-            return $this->path . "/" . $this->slug;
65
+            return $this->path."/".$this->slug;
66 66
         else
67 67
             return '';
68 68
 
@@ -183,17 +183,17 @@  discard block
 block discarded – undo
183 183
 
184 184
         preg_match_all("/[a-z0-9]+/", iconv("UTF-8", "ASCII//TRANSLIT", strtolower(preg_replace('/\..*?$/', '', $this->fname))), $matches);
185 185
 
186
-        $this->slug  = implode('-', $matches[0]);
186
+        $this->slug = implode('-', $matches[0]);
187 187
 
188 188
         if (!empty($this->path)) {
189 189
 
190
-            $files = glob($this->path . "/" . $slug . "*");
190
+            $files = glob($this->path."/".$slug."*");
191 191
 
192
-            $count = count ($files);
192
+            $count = count($files);
193 193
 
194 194
             if ($count > 0) {
195 195
 
196
-                $this->slug .= "-" . $count;
196
+                $this->slug .= "-".$count;
197 197
 
198 198
             }
199 199
 
Please login to merge, or discard this patch.
src/Comodojo/Dispatcher/Request/Model.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@
 block discarded – undo
52 52
 
53 53
         $this->version = new Version();
54 54
         
55
-        $repo = (!empty($configuration->get('repository')))?$configuration->get('base-path') . "/" . $configuration->get('repository'):'';
55
+        $repo = (!empty($configuration->get('repository'))) ? $configuration->get('base-path')."/".$configuration->get('repository') : '';
56 56
         
57 57
         $this->file = File::fromUploadedFiles($repo);
58 58
 
Please login to merge, or discard this patch.
src/Comodojo/Dispatcher/Router/Route.php 1 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
 
73 73
     public function getServiceName() {
74 74
 
75
-        return (empty($this->service))?"default":implode('.', $this->service);
75
+        return (empty($this->service)) ? "default" : implode('.', $this->service);
76 76
 
77 77
     }
78 78
 
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
 
97 97
         $parameters = $this->parameters;
98 98
 
99
-        return (isset($parameters[$key]))?$parameters[$key]:null;
99
+        return (isset($parameters[$key])) ? $parameters[$key] : null;
100 100
 
101 101
     }
102 102
 
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
 
127 127
         $parameters = $this->request;
128 128
 
129
-        return (isset($parameters[$key]))?$parameters[$key]:null;
129
+        return (isset($parameters[$key])) ? $parameters[$key] : null;
130 130
 
131 131
     }
132 132
 
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
 
170 170
         $query = $this->query;
171 171
 
172
-        return isset($query[$key])?$query[$key]["required"]:false;
172
+        return isset($query[$key]) ? $query[$key]["required"] : false;
173 173
 
174 174
     }
175 175
 
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
 
178 178
         $query = $this->query;
179 179
 
180
-        return isset($query[$key])?$query[$key]["regex"]:null;
180
+        return isset($query[$key]) ? $query[$key]["regex"] : null;
181 181
 
182 182
     }
183 183
 
@@ -218,7 +218,7 @@  discard block
 block discarded – undo
218 218
                 /* if it's available a bit associated with the parameter name, it is compared against
219 219
                  * it's regular expression in order to extrect backreferences
220 220
                  */
221
-                if (preg_match('/^' . $value['regex'] . '$/', $path[$key], $matches)) {
221
+                if (preg_match('/^'.$value['regex'].'$/', $path[$key], $matches)) {
222 222
 
223 223
                     if (count($matches) == 1) $matches = $matches[0]; // This is the case where no backreferences are present or available.
224 224
 
Please login to merge, or discard this patch.