aboutsummaryrefslogtreecommitdiff
path: root/discord/client.py
diff options
context:
space:
mode:
authorRapptz <[email protected]>2017-07-04 20:01:27 -0400
committerRapptz <[email protected]>2017-07-04 20:02:17 -0400
commit3bd0c2120c1d05fe49fd9a873b0b0e4aedd43066 (patch)
treed9a10cf0de5c8d15b0104f00706f002a7e831d0c /discord/client.py
parentDon't unnecessarily re-create private channels. (diff)
downloaddiscord.py-3bd0c2120c1d05fe49fd9a873b0b0e4aedd43066.tar.xz
discord.py-3bd0c2120c1d05fe49fd9a873b0b0e4aedd43066.zip
Implement a LRU cache for private channels.
Another fix related to the discord issue[1]. [1]: https://github.com/hammerandchisel/discord-api-docs/issues/184
Diffstat (limited to 'discord/client.py')
-rw-r--r--discord/client.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/discord/client.py b/discord/client.py
index 6304fb4e..2c5ed69c 100644
--- a/discord/client.py
+++ b/discord/client.py
@@ -179,7 +179,13 @@ class Client:
@property
def private_channels(self):
- """List[:class:`abc.PrivateChannel`]: The private channels that the connected client is participating on."""
+ """List[:class:`abc.PrivateChannel`]: The private channels that the connected client is participating on.
+
+ .. note::
+
+ This returns only up to 128 most recent private channels due to an internal working
+ on how Discord deals with private channels.
+ """
return self._connection.private_channels
@property