protected function emitHeaders(ResponseInterface $response)
    {
        $normalize = function ($headerName) {
            $name     = str_replace('-', ' ', $headerName);
            $filtered = str_replace(' ', '-', ucwords($name));

            return $filtered;
        };
        foreach ($response->getHeaders() as $headerName => $values) {
            $name  = $normalize($headerName);
            $first = true;
            foreach ($values as $value) {
                header(sprintf(
                    '%s: %s',
                    $name,
                    $value
                ), $first);
                $first = false;
            }
        }

        return $this;
    }