| @@ -27,13 +27,13 @@ | ||
| 27 | 27 | $request->getUri()->getPath() | 
| 28 | 28 | ); | 
| 29 | 29 | |
| 30 | -        $service = match ($routeInfo[0]) { | |
| 30 | +        $service = match($routeInfo[0]) { | |
| 31 | 31 | FastRoute\Dispatcher::NOT_FOUND => Constants\Services::NOT_FOUND_HANDLER->value, | 
| 32 | 32 | FastRoute\Dispatcher::METHOD_NOT_ALLOWED => Constants\Services::BAD_METHOD_HANDLER->value, | 
| 33 | 33 | FastRoute\Dispatcher::FOUND => $routeInfo[1] | 
| 34 | 34 | }; | 
| 35 | 35 | |
| 36 | -        $request = match ($service) { | |
| 36 | +        $request = match($service) { | |
| 37 | 37 | Constants\Services::NOT_FOUND_HANDLER->value => $request, | 
| 38 | 38 | |
| 39 | 39 | Constants\Services::BAD_METHOD_HANDLER->value => | 
| @@ -35,7 +35,7 @@ | ||
| 35 | 35 | [$name], | 
| 36 | 36 | array_filter( | 
| 37 | 37 | array_unique($groups), | 
| 38 | -                static function (string $group) use ($name): bool { | |
| 38 | +                static function(string $group) use ($name): bool { | |
| 39 | 39 | return $group !== $name; | 
| 40 | 40 | } | 
| 41 | 41 | ) | 
| @@ -132,10 +132,10 @@ discard block | ||
| 132 | 132 | |
| 133 | 133 |          try { | 
| 134 | 134 | $handler = Internal\Assert::isRequestHandler($this->container->get($handlerName)); | 
| 135 | -            $middlewareChain = array_map(function (string $name): Server\MiddlewareInterface { | |
| 135 | +            $middlewareChain = array_map(function(string $name): Server\MiddlewareInterface { | |
| 136 | 136 | return $this->container->get($name); | 
| 137 | 137 | }, $middlewareChainNames); | 
| 138 | -        } catch (ContainerExceptionInterface|TypeError $e) { | |
| 138 | +        } catch (ContainerExceptionInterface | TypeError $e) { | |
| 139 | 139 | throw new LogicException(message: $e->getMessage(), previous: $e); | 
| 140 | 140 | } | 
| 141 | 141 | |
| @@ -156,8 +156,7 @@ discard block | ||
| 156 | 156 | public function run(): void | 
| 157 | 157 |      { | 
| 158 | 158 | $request = $this->container->has(Constants\Settings::SERVER_REQUEST_CREATOR->value) ? | 
| 159 | - $this->container->get(Constants\Settings::SERVER_REQUEST_CREATOR->value)->fromGlobals() : | |
| 160 | - Internal\ServerRequestPicker::fromGlobals(); | |
| 159 | + $this->container->get(Constants\Settings::SERVER_REQUEST_CREATOR->value)->fromGlobals() : Internal\ServerRequestPicker::fromGlobals(); | |
| 161 | 160 | |
| 162 | 161 | $response = $this->handle($request); | 
| 163 | 162 | |
| @@ -35,16 +35,15 @@ | ||
| 35 | 35 |          try { | 
| 36 | 36 | return $handler->handle($request); | 
| 37 | 37 |          } catch (Throwable $t) { | 
| 38 | - error_log((string)$t); | |
| 38 | + error_log((string) $t); | |
| 39 | 39 | |
| 40 | 40 | $response = $this->responseFactory | 
| 41 | 41 | ->createResponse(500); | 
| 42 | 42 | |
| 43 | 43 | return $this->hide ? | 
| 44 | - $response : | |
| 45 | - $response | |
| 44 | + $response : $response | |
| 46 | 45 |                      ->withHeader('Content-Type', 'text/plain') | 
| 47 | - ->withBody($this->streamFactory->createStream((string)$t)); | |
| 46 | + ->withBody($this->streamFactory->createStream((string) $t)); | |
| 48 | 47 | } | 
| 49 | 48 | } | 
| 50 | 49 | } |