| Total Complexity | 1 |
| Total Lines | 9 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 10 | class SetRequestAttributesWithoutRouteIdToResponseHeaderMiddlewareTest implements MiddlewareInterface |
||
| 11 | { |
||
| 12 | public function process(ServerRequestInterface $request, RequestHandlerInterface $handler) : ResponseInterface |
||
| 13 | { |
||
| 14 | $attributes = $request->getAttributes(); |
||
| 15 | |||
| 16 | unset($attributes['@route']); |
||
| 17 | |||
| 18 | return $handler->handle($request)->withHeader('x-request-attributes', \implode(', ', $attributes)); |
||
| 19 | } |
||
| 21 |