@@ -66,7 +66,7 @@ |
||
66 | 66 | |
67 | 67 | $route = $this; |
68 | 68 | |
69 | - return function (Request $request, Response $response) use ($route) { |
|
69 | + return function(Request $request, Response $response) use ($route) { |
|
70 | 70 | list($controller, $action) = explode(':', str_replace('::', ':', $route->target)); |
71 | 71 | |
72 | 72 | if ($action == self::DYNAMIC_ACTION) { |
@@ -123,7 +123,7 @@ discard block |
||
123 | 123 | { |
124 | 124 | $route = $this; |
125 | 125 | |
126 | - return function (Request $request, Response $response) use ($route) { |
|
126 | + return function(Request $request, Response $response) use ($route) { |
|
127 | 127 | $matches = $route->getMatches(); |
128 | 128 | |
129 | 129 | //Due we are expecting part of class name we can remove some garbage (see to-do below) |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | //Aliased |
134 | 134 | $controller = $route->controllers[$controller]; |
135 | 135 | } else { |
136 | - $controller = Inflector::classify($controller) . $route->postfix; |
|
136 | + $controller = Inflector::classify($controller).$route->postfix; |
|
137 | 137 | $controller = "{$route->namespace}\\{$controller}"; |
138 | 138 | } |
139 | 139 |
@@ -116,7 +116,7 @@ |
||
116 | 116 | $response = $response->withHeader('Content-Length', (string)$stream->getSize()); |
117 | 117 | $response = $response->withHeader( |
118 | 118 | 'Content-Disposition', |
119 | - 'attachment; filename="' . addcslashes($name, '"') . '"' |
|
119 | + 'attachment; filename="'.addcslashes($name, '"').'"' |
|
120 | 120 | ); |
121 | 121 | |
122 | 122 | return $response->withBody($stream); |
@@ -143,7 +143,7 @@ |
||
143 | 143 | if (empty($path)) { |
144 | 144 | return '/'; |
145 | 145 | } elseif ($path[0] !== '/') { |
146 | - return '/' . $path; |
|
146 | + return '/'.$path; |
|
147 | 147 | } |
148 | 148 | |
149 | 149 | return $path; |
@@ -246,7 +246,7 @@ |
||
246 | 246 | } |
247 | 247 | |
248 | 248 | foreach (array_keys($iteration) as $key) { |
249 | - $result[$key] = $prefix . '.' . $key; |
|
249 | + $result[$key] = $prefix.'.'.$key; |
|
250 | 250 | } |
251 | 251 | |
252 | 252 | return $result; |
@@ -44,7 +44,7 @@ |
||
44 | 44 | } |
45 | 45 | |
46 | 46 | //Action should include prefix and be always specified |
47 | - $method = static::ACTION_PREFIX . ($action ?? $this->defaultAction) . static::ACTION_POSTFIX; |
|
47 | + $method = static::ACTION_PREFIX.($action ?? $this->defaultAction).static::ACTION_POSTFIX; |
|
48 | 48 | if (!method_exists($this, $method)) { |
49 | 49 | throw new ControllerException( |
50 | 50 | "No such action '{$action}'", ControllerException::BAD_ACTION |
@@ -97,7 +97,7 @@ |
||
97 | 97 | } |
98 | 98 | |
99 | 99 | //We need unique temporary variable |
100 | - $tempVariable = 'evaluator_' . str_replace('.', '_', uniqid('', true)); |
|
100 | + $tempVariable = 'evaluator_'.str_replace('.', '_', uniqid('', true)); |
|
101 | 101 | |
102 | 102 | $lines = [ |
103 | 103 | $this->extractCode($tempVariable, $matches[3]), |
@@ -212,7 +212,7 @@ |
||
212 | 212 | } |
213 | 213 | |
214 | 214 | $strings = []; |
215 | - array_walk_recursive($target, function ($value) use (&$strings) { |
|
215 | + array_walk_recursive($target, function($value) use (&$strings) { |
|
216 | 216 | if (is_string($value) && $this->hasBraces($value)) { |
217 | 217 | $strings[] = $this->removeBraces($value); |
218 | 218 | } |
@@ -52,7 +52,7 @@ |
||
52 | 52 | |
53 | 53 | foreach ($locator->getViews($namespace) as $view => $engine) { |
54 | 54 | if ($this->isVerbosity()) { |
55 | - $this->write($formatter->formatSection("{$engine}", $view . ", ", 'fg=cyan')); |
|
55 | + $this->write($formatter->formatSection("{$engine}", $view.", ", 'fg=cyan')); |
|
56 | 56 | } |
57 | 57 | |
58 | 58 | $start = microtime(true); |