@@ -101,7 +101,7 @@ |
||
101 | 101 | if (!file_exists($filename)) { |
102 | 102 | $crypt = new Crypt($this->config); |
103 | 103 | $accounts = $this->config->getSettings(Config::_ACCOUNTS); |
104 | - $accounts = array_map(function ($acc) use ($crypt) { |
|
104 | + $accounts = array_map(function($acc) use ($crypt) { |
|
105 | 105 | $acc[self::_PASSWORD] = $crypt->encrypt( |
106 | 106 | $acc[self::_PASSWORD], |
107 | 107 | true |
@@ -68,7 +68,7 @@ |
||
68 | 68 | { |
69 | 69 | if (is_null($this->instance)) { |
70 | 70 | try { |
71 | - $this->instance = new Redis(); |
|
71 | + $this->instance = new Redis(); |
|
72 | 72 | $cresult = @$this->instance->connect( |
73 | 73 | $this->config[self::_HOST], |
74 | 74 | $this->config[self::_PORT] |
@@ -47,7 +47,7 @@ |
||
47 | 47 | 'exclude' => [ |
48 | 48 | 'auth/login', 'stat/opcache', |
49 | 49 | 'restful', 'restful/index', |
50 | - 'test/pokerelay' , 'test/redis' |
|
50 | + 'test/pokerelay', 'test/redis' |
|
51 | 51 | ], |
52 | 52 | ], |
53 | 53 | After::class => [ |
@@ -83,7 +83,7 @@ |
||
83 | 83 | public function getRaw(): array |
84 | 84 | { |
85 | 85 | return array_map( |
86 | - function ($key, $val) { |
|
86 | + function($key, $val) { |
|
87 | 87 | return $key . ': ' . $val; |
88 | 88 | }, |
89 | 89 | array_keys($this->headers), |
@@ -159,7 +159,7 @@ |
||
159 | 159 | { |
160 | 160 | if ($this->constructable($serviceName)) { |
161 | 161 | if (!$this->hasService($serviceName)) { |
162 | - $args = array_map(function ($value) { |
|
162 | + $args = array_map(function($value) { |
|
163 | 163 | if (is_array($value)) { |
164 | 164 | $values = []; |
165 | 165 | foreach ($value as $i) { |
@@ -54,7 +54,7 @@ |
||
54 | 54 | public function getExpr(): array |
55 | 55 | { |
56 | 56 | $patterns = array_map( |
57 | - function (Route $i) { |
|
57 | + function(Route $i) { |
|
58 | 58 | return $i->getExpr(); |
59 | 59 | }, |
60 | 60 | $this->routes |
@@ -189,7 +189,7 @@ |
||
189 | 189 | $v = ($type == \PDO::PARAM_INT) ? (int) $v : $v; |
190 | 190 | } |
191 | 191 | $value = is_array($v) ? serialize($v) : $v; |
192 | - $key = $k; |
|
192 | + $key = $k; |
|
193 | 193 | try { |
194 | 194 | $poStatement->bindValue($key, $value, $type); |
195 | 195 | } catch (\PDOException $e) { |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | */ |
94 | 94 | protected function createCoreFunction(Closure $core): Closure |
95 | 95 | { |
96 | - return function ($object) use ($core) { |
|
96 | + return function($object) use ($core) { |
|
97 | 97 | return $core($object); |
98 | 98 | }; |
99 | 99 | } |
@@ -108,7 +108,7 @@ discard block |
||
108 | 108 | */ |
109 | 109 | protected function createLayer(Closure $nextLayer, ILayer $layer): Closure |
110 | 110 | { |
111 | - return function ($object) use ($nextLayer, $layer) { |
|
111 | + return function($object) use ($nextLayer, $layer) { |
|
112 | 112 | return $layer->peel($object, $nextLayer); |
113 | 113 | }; |
114 | 114 | } |
@@ -249,7 +249,7 @@ discard block |
||
249 | 249 | } |
250 | 250 | (new Middleware())->layer($this->middlewares)->peel( |
251 | 251 | $this->container, |
252 | - function ($container) { |
|
252 | + function($container) { |
|
253 | 253 | $this->execute($this->router->getParams()); |
254 | 254 | return $container; |
255 | 255 | } |
@@ -339,7 +339,7 @@ discard block |
||
339 | 339 | protected function setActions() |
340 | 340 | { |
341 | 341 | $methods = $this->getFinalMethods(); |
342 | - $methodsName = array_map(function ($method) { |
|
342 | + $methodsName = array_map(function($method) { |
|
343 | 343 | return $method->name; |
344 | 344 | }, $methods); |
345 | 345 | $this->actions = array_merge($methodsName, ['preflight']); |