This commit is contained in:
2021-08-10 17:52:07 +08:00
parent cc83805fd6
commit 63d8eaa4a5
2 changed files with 1 additions and 1 deletions
-1
View File
@@ -211,7 +211,6 @@ class Response extends HttpService implements ResponseInterface
public function configure(SResponse $response): static
{
$response->setStatusCode($this->statusCode);
$response->header('Content-Type', $this->getResponseFormat());
$response->header('Run-Time', $this->getRuntime());
if (!empty($this->headers)) {
foreach ($this->headers as $name => $header) {
+1
View File
@@ -29,6 +29,7 @@ class ResponseEmitter
if ($content instanceof FileFormatter) {
$this->download($content->getData(), $response);
} else {
$response->header('Content-Type', $emitter->getResponseFormat());
$response->end($content->getData());
}
}