From efc2d04ead010c46e0fc73c3cb145758d2a2abb3 Mon Sep 17 00:00:00 2001 From: Adam Johnson Date: Tue, 26 Jul 2022 18:47:05 +0100 Subject: [PATCH] Improve types for @require_http_methods (#1075) --- django-stubs/views/decorators/http.pyi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/django-stubs/views/decorators/http.pyi b/django-stubs/views/decorators/http.pyi index 9e4dc95..17ea232 100644 --- a/django-stubs/views/decorators/http.pyi +++ b/django-stubs/views/decorators/http.pyi @@ -1,10 +1,10 @@ -from typing import Any, Callable, List, Optional, TypeVar +from typing import Any, Callable, Container, Optional, TypeVar _F = TypeVar("_F", bound=Callable[..., Any]) conditional_page: Callable[[_F], _F] = ... -def require_http_methods(request_method_list: List[str]) -> Callable[[_F], _F]: ... +def require_http_methods(request_method_list: Container[str]) -> Callable[[_F], _F]: ... require_GET: Callable[[_F], _F] = ... require_POST: Callable[[_F], _F] = ...