From faed32b5ade70fab61d7a481a9f97455ba8aee4f Mon Sep 17 00:00:00 2001 From: gustavofreze Date: Sat, 1 Jul 2023 11:13:47 -0300 Subject: [PATCH] fix: Fix typing for HttpResponse.php. --- src/HttpResponse.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/HttpResponse.php b/src/HttpResponse.php index 7c079f2..92fd54d 100644 --- a/src/HttpResponse.php +++ b/src/HttpResponse.php @@ -17,17 +17,17 @@ public static function ok(mixed $data, ?HttpHeaders $headers = null): ResponseIn return Response::from(code: HttpCode::OK, data: $data, headers: $headers); } - public static function created(mixed $data, HttpHeaders $headers = null): ResponseInterface + public static function created(mixed $data, ?HttpHeaders $headers = null): ResponseInterface { return Response::from(code: HttpCode::CREATED, data: $data, headers: $headers); } - public static function accepted(mixed $data, HttpHeaders $headers = null): ResponseInterface + public static function accepted(mixed $data, ?HttpHeaders $headers = null): ResponseInterface { return Response::from(code: HttpCode::ACCEPTED, data: $data, headers: $headers); } - public static function noContent(HttpHeaders $headers = null): ResponseInterface + public static function noContent(?HttpHeaders $headers = null): ResponseInterface { return Response::from(code: HttpCode::NO_CONTENT, data: null, headers: $headers); }