From 2067819b756f20d73256fb2988cc0839946eee16 Mon Sep 17 00:00:00 2001 From: Rapptz Date: Sun, 17 Jul 2022 21:40:05 -0400 Subject: [PATCH] Fix some minor typing errors --- discord/http.py | 2 ++ discord/template.py | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/discord/http.py b/discord/http.py index d1cd7f234..3cfa359ad 100644 --- a/discord/http.py +++ b/discord/http.py @@ -534,6 +534,8 @@ class HTTPClient: else: raise HTTPException(resp, 'failed to get asset') + raise RuntimeError('Unreachable') + # state management async def close(self) -> None: diff --git a/discord/template.py b/discord/template.py index e420e537c..367b81c6f 100644 --- a/discord/template.py +++ b/discord/template.py @@ -24,7 +24,7 @@ DEALINGS IN THE SOFTWARE. from __future__ import annotations -from typing import Any, Optional, TYPE_CHECKING +from typing import Any, Optional, TYPE_CHECKING, List from .utils import parse_time, _bytes_to_base64_data, MISSING from .guild import Guild @@ -81,7 +81,7 @@ class _PartialTemplateState: def _get_guild(self, id): return self.__state._get_guild(id) - async def query_members(self, **kwargs: Any) -> list: + async def query_members(self, **kwargs: Any) -> List[Any]: return [] def __getattr__(self, attr):