diff options
| author | Rapptz <[email protected]> | 2020-01-12 02:44:09 -0500 |
|---|---|---|
| committer | Rapptz <[email protected]> | 2020-01-12 02:44:16 -0500 |
| commit | bfaf8ecfdb2323f66f95b61d32e6b87277d4616a (patch) | |
| tree | fafc706fa8d8c083b59526a965e14dbaa677c47a /discord/guild.py | |
| parent | Redesign permissions to allow aliases to be used. (diff) | |
| download | discord.py-bfaf8ecfdb2323f66f95b61d32e6b87277d4616a.tar.xz discord.py-bfaf8ecfdb2323f66f95b61d32e6b87277d4616a.zip | |
Allow Guild.fetch_members to take in limit=None
Fixes #2473
Diffstat (limited to 'discord/guild.py')
| -rw-r--r-- | discord/guild.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/discord/guild.py b/discord/guild.py index b617e8ac..fa7b320c 100644 --- a/discord/guild.py +++ b/discord/guild.py @@ -633,7 +633,7 @@ class Guild(Hashable): @property def discovery_splash_url(self): """:class:`Asset`: Returns the guild's discovery splash asset. - + .. versionadded:: 1.3.0 """ return self.discovery_splash_url_as() @@ -1130,7 +1130,7 @@ class Guild(Hashable): return [convert(d) for d in data] - def fetch_members(self, *, limit=1, after=None): + def fetch_members(self, *, limit=1000, after=None): """|coro| Retrieves an :class:`.AsyncIterator` that enables receiving the guild's members. @@ -1146,8 +1146,8 @@ class Guild(Hashable): Parameters ---------- limit: Optional[:class:`int`] - The number of members to retrieve. - Defaults to 1. + The number of members to retrieve. Defaults to 1000. + Pass ``None`` to fetch all members. Note that this is potentially slow. after: Optional[Union[:class:`.abc.Snowflake`, :class:`datetime.datetime`]] Retrieve members after this date or object. If a date is provided it must be a timezone-naive datetime representing UTC time. |