From 6268cad40297e6eeaddf64653ae8978171dddd76 Mon Sep 17 00:00:00 2001 From: Rapptz Date: Sun, 22 Aug 2021 02:28:37 -0400 Subject: [PATCH] ResponseType type alias is private --- discord/errors.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/discord/errors.py b/discord/errors.py index 398cdc556..bc2398d55 100644 --- a/discord/errors.py +++ b/discord/errors.py @@ -31,9 +31,9 @@ if TYPE_CHECKING: try: from requests import Response - ResponseType = Union[ClientResponse, Response] + _ResponseType = Union[ClientResponse, Response] except ModuleNotFoundError: - ResponseType = ClientResponse + _ResponseType = ClientResponse from .interactions import Interaction @@ -123,8 +123,8 @@ class HTTPException(DiscordException): The Discord specific error code for the failure. """ - def __init__(self, response: ResponseType, message: Optional[Union[str, Dict[str, Any]]]): - self.response: ResponseType = response + def __init__(self, response: _ResponseType, message: Optional[Union[str, Dict[str, Any]]]): + self.response: _ResponseType = response self.status: int = response.status # type: ignore self.code: int self.text: str