diff options
Diffstat (limited to 'discord/client.py')
| -rw-r--r-- | discord/client.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/discord/client.py b/discord/client.py index f30ed7f5..494a838a 100644 --- a/discord/client.py +++ b/discord/client.py @@ -22,12 +22,14 @@ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. """ +from __future__ import annotations + import asyncio import logging import signal import sys import traceback -from typing import Any, Optional, Union +from typing import Any, List, Optional, TYPE_CHECKING, Union import aiohttp @@ -58,6 +60,9 @@ __all__ = ( 'Client', ) +if TYPE_CHECKING: + from .abc import SnowflakeTime + log = logging.getLogger(__name__) def _cancel_tasks(loop): @@ -968,7 +973,7 @@ class Client: # Guild stuff - def fetch_guilds(self, *, limit=100, before=None, after=None): + def fetch_guilds(self, *, limit: int = 100, before: SnowflakeTime = None, after: SnowflakeTime = None) -> List[Guild]: """Retrieves an :class:`.AsyncIterator` that enables receiving your guilds. .. note:: |