| Total Complexity | 2 |
| Total Lines | 24 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 14 | class ServerMiddleware implements MiddlewareInterface |
||
| 15 | { |
||
| 16 | /** |
||
| 17 | * Process an incoming server request (PSR-15). |
||
| 18 | * |
||
| 19 | * @param ServerRequest $request |
||
| 20 | * @param RequestHandler $handler |
||
| 21 | * @return Response |
||
| 22 | * @throws \RuntimeException if unauthorized response can't be created |
||
| 23 | */ |
||
| 24 | 1 | public function process(ServerRequest $request, RequestHandler $handler): Response |
|
| 27 | } |
||
| 28 | |||
| 29 | /** |
||
| 30 | * Get a callback that can be used as double pass middleware. |
||
| 31 | * |
||
| 32 | * @return callable |
||
| 33 | */ |
||
| 34 | 1 | public function asDoublePass(): callable |
|
| 41 |