@@ -48,7 +48,7 @@ |
||
48 | 48 | $routes = $this->config->toArray(); |
49 | 49 | |
50 | 50 | $this->adapter = \FastRoute\simpleDispatcher( |
51 | - function (RouteCollector $routeCollector) use ($routes) { |
|
51 | + function(RouteCollector $routeCollector) use ($routes) { |
|
52 | 52 | foreach ($routes as $route) { |
53 | 53 | $method = $route['allowed_methods']; |
54 | 54 | $uri = $route['path']; |
@@ -59,7 +59,7 @@ |
||
59 | 59 | $this->adapter->addExtension(new Twig_Extension_Debug()); |
60 | 60 | |
61 | 61 | $viewPath = $this->templateViewPath; |
62 | - $function = new Twig_SimpleFunction('defined', function ($fileName) use ($viewPath) { |
|
62 | + $function = new Twig_SimpleFunction('defined', function($fileName) use ($viewPath) { |
|
63 | 63 | $fileName = str_replace('@Theme', $viewPath, $fileName); |
64 | 64 | return file_exists($fileName); |
65 | 65 | }); |
@@ -14,8 +14,8 @@ |
||
14 | 14 | namespace WebHemi\Auth; |
15 | 15 | |
16 | 16 | use WebHemi\Adapter\Auth\AbstractAuthAdapter; |
17 | -use WebHemi\Data\Entity\User\UserEntity; |
|
18 | 17 | use WebHemi\Data\Entity\DataEntityInterface; |
18 | +use WebHemi\Data\Entity\User\UserEntity; |
|
19 | 19 | use WebHemi\Data\Storage\User\UserStorage; |
20 | 20 | |
21 | 21 | /** |
@@ -51,7 +51,7 @@ |
||
51 | 51 | * |
52 | 52 | * @return DataEntityInterface|null |
53 | 53 | */ |
54 | - public function getIdentity() : ?DataEntityInterface |
|
54 | + public function getIdentity() : ? DataEntityInterface |
|
55 | 55 | { |
56 | 56 | $identity = parent::getIdentity(); |
57 | 57 | // TODO implement |
@@ -135,7 +135,7 @@ |
||
135 | 135 | string $name, |
136 | 136 | int $timeOut = 3600, |
137 | 137 | string $path = '/', |
138 | - ?string $domain = null, |
|
138 | + ? string $domain = null, |
|
139 | 139 | bool $secure = false, |
140 | 140 | bool $httpOnly = false |
141 | 141 | ) : SessionManager { |
@@ -347,7 +347,7 @@ |
||
347 | 347 | * @param string $subDirectory |
348 | 348 | * @return bool |
349 | 349 | */ |
350 | - private function checkDomainIsValid(string $applicationName, array $applicationData, string &$subDirectory) : bool |
|
350 | + private function checkDomainIsValid(string $applicationName, array $applicationData, string&$subDirectory) : bool |
|
351 | 351 | { |
352 | 352 | $isSubdomain = $applicationName == 'website' |
353 | 353 | || ( |
@@ -181,7 +181,7 @@ discard block |
||
181 | 181 | * |
182 | 182 | * @return null|string |
183 | 183 | */ |
184 | - public function start() : ?string |
|
184 | + public function start() : ? string |
|
185 | 185 | { |
186 | 186 | $this->index = 0; |
187 | 187 | $this->sortPipeline(); |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | * |
195 | 195 | * @return null|string |
196 | 196 | */ |
197 | - public function next() : ?string |
|
197 | + public function next() : ? string |
|
198 | 198 | { |
199 | 199 | if (!isset($this->index)) { |
200 | 200 | throw new RuntimeException('Unable to get the next element until the pipeline is not started.', 1003); |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | * @throws RuntimeException |
60 | 60 | * @return int The ID of the saved entity in the storage |
61 | 61 | */ |
62 | - public function saveData(?int $identifier = null, array $data) : int |
|
62 | + public function saveData(? int $identifier = null, array $data) : int |
|
63 | 63 | { |
64 | 64 | return empty($identifier) ? $this->insertData($data) : $this->updateData($identifier, $data); |
65 | 65 | } |
@@ -94,7 +94,7 @@ discard block |
||
94 | 94 | $this->bindValuesToStatement($statement, $queryBind); |
95 | 95 | $statement->execute(); |
96 | 96 | |
97 | - return (int)$this->dataDriver->lastInsertId(); |
|
97 | + return (int) $this->dataDriver->lastInsertId(); |
|
98 | 98 | } |
99 | 99 | |
100 | 100 | /** |
@@ -278,7 +278,7 @@ discard block |
||
278 | 278 | * |
279 | 279 | * @codeCoverageIgnore Don't test external library. |
280 | 280 | */ |
281 | - public function saveData(?int $identifier = null, array $data) : int |
|
281 | + public function saveData(? int $identifier = null, array $data) : int |
|
282 | 282 | { |
283 | 283 | if (empty($identifier)) { |
284 | 284 | $query = "INSERT INTO {$this->dataGroup}"; |
@@ -308,7 +308,7 @@ discard block |
||
308 | 308 | $this->bindValuesToStatement($statement, $queryBind); |
309 | 309 | $statement->execute(); |
310 | 310 | |
311 | - return empty($identifier) ? (int)$this->dataDriver->lastInsertId() : $identifier; |
|
311 | + return empty($identifier) ? (int) $this->dataDriver->lastInsertId() : $identifier; |
|
312 | 312 | } |
313 | 313 | |
314 | 314 | /** |
@@ -81,7 +81,7 @@ |
||
81 | 81 | * @param array $data |
82 | 82 | * @return int The ID of the saved entity in the storage |
83 | 83 | */ |
84 | - public function saveData(?int $identifier, array $data) : int; |
|
84 | + public function saveData(? int $identifier, array $data) : int; |
|
85 | 85 | |
86 | 86 | /** |
87 | 87 | * Removes an entity from the storage. |