X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/44d5da00b520a05cd56e58b3998660f64ea59ebd..92c93a278036870a76740d5b0b8f06504925e7dc:/src/blackd/middlewares.py diff --git a/src/blackd/middlewares.py b/src/blackd/middlewares.py index 7abde52..e71f508 100644 --- a/src/blackd/middlewares.py +++ b/src/blackd/middlewares.py @@ -9,7 +9,7 @@ Middleware = Callable[[Request, Handler], Awaitable[StreamResponse]] def cors(allow_headers: Iterable[str]) -> Middleware: - @middleware + @middleware # type: ignore[misc] async def impl(request: Request, handler: Handler) -> StreamResponse: is_options = request.method == "OPTIONS" is_preflight = is_options and "Access-Control-Request-Method" in request.headers @@ -32,4 +32,4 @@ def cors(allow_headers: Iterable[str]) -> Middleware: return resp - return impl # type: ignore + return impl # type: ignore[no-any-return]