From: Marcelo Trylesinski Date: Sat, 10 Jun 2023 17:04:29 +0000 (+0200) Subject: ♻ Remove `media_type` from `ORJSONResponse` as it's inherited from the parent class... X-Git-Tag: 0.96.1~17 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=52fd0afc945e503a56725e79f5d44fb9a7c75f09;p=thirdparty%2Ffastapi%2Ffastapi.git ♻ Remove `media_type` from `ORJSONResponse` as it's inherited from the parent class (#5805) Co-authored-by: Sebastián Ramírez --- diff --git a/fastapi/responses.py b/fastapi/responses.py index 88dba96e8f..c0a13b7555 100644 --- a/fastapi/responses.py +++ b/fastapi/responses.py @@ -27,8 +27,6 @@ class UJSONResponse(JSONResponse): class ORJSONResponse(JSONResponse): - media_type = "application/json" - def render(self, content: Any) -> bytes: assert orjson is not None, "orjson must be installed to use ORJSONResponse" return orjson.dumps(