From 16e2b481948bcb0ab310062465d9faea38f28f61 Mon Sep 17 00:00:00 2001 From: Ruwann Date: Thu, 30 May 2024 09:15:33 +0200 Subject: [PATCH] Update connexion/decorators/response.py --- connexion/decorators/response.py | 1 + 1 file changed, 1 insertion(+) diff --git a/connexion/decorators/response.py b/connexion/decorators/response.py index 97662c3a9..0aa58870d 100644 --- a/connexion/decorators/response.py +++ b/connexion/decorators/response.py @@ -138,6 +138,7 @@ def _unpack_handler_response( elif len(handler_response) == 2: data, status_code_or_headers = handler_response if isinstance(status_code_or_headers, int): + # Extra int call because of int subclasses such as http.HTTPStatus (IntEnum) status_code = int(status_code_or_headers) elif isinstance(status_code_or_headers, Enum) and isinstance( status_code_or_headers.value, int