From 033e2cff11beb1c7fa702f32e99005eed786674a Mon Sep 17 00:00:00 2001 From: reton2 Date: Wed, 1 May 2024 11:51:22 +0100 Subject: [PATCH] fix: linting issue --- fastapi/routing.py | 1 + 1 file changed, 1 insertion(+) diff --git a/fastapi/routing.py b/fastapi/routing.py index c34a54733..6dd7d0fe4 100644 --- a/fastapi/routing.py +++ b/fastapi/routing.py @@ -211,6 +211,7 @@ def get_request_handler( is_coroutine = ( asyncio.iscoroutinefunction(dependant.call) or callable(dependant.call) + and hasattr(dependant.call, "__call__") and inspect.iscoroutinefunction(dependant.call.__call__) ) is_body_form = body_field and isinstance(body_field.field_info, params.Form)