summaryrefslogtreecommitdiff
path: root/tests/http/headers.php
blob: b6f3967a5ea630ae980549ed41926d3a80d5a067 (plain)
1
2
3
4
5
6
7
8
9
10
11
<?php

use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;

function handleRequest(ServerRequestInterface $req, ResponseInterface $resp): ResponseInterface
{
    $resp->getBody()->write(json_encode($req->getHeaders()));

    return $resp;
}