diff --git a/src/Constrict/ConstrictResponse.php b/src/Constrict/ConstrictResponse.php index 236f357..a5cbe77 100644 --- a/src/Constrict/ConstrictResponse.php +++ b/src/Constrict/ConstrictResponse.php @@ -36,7 +36,7 @@ class ConstrictResponse extends Message implements ResponseInterface * @param ContentType $type * @return $this */ - public function write(mixed $data, int $statusCode = 200, ContentType $type = ContentType::JSON): static + public function write(mixed $data, int $statusCode = 200, ContentType $type = ContentType::HTML): static { if ($data instanceof \Stringable) { $this->getBody()->write($data->__toString()); diff --git a/src/Response.php b/src/Response.php index 419399b..d452652 100644 --- a/src/Response.php +++ b/src/Response.php @@ -78,7 +78,7 @@ class Response implements ResponseInterface * @param ContentType $type * @return Response */ - public function write(mixed $data, int $statusCode = 200, ContentType $type = ContentType::JSON): static + public function write(mixed $data, int $statusCode = 200, ContentType $type = ContentType::HTML): static { return $this->__call__(__FUNCTION__, $data, $statusCode, $type); }