mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-09-08 10:53:10 +00:00
add read-only cached_messages property to Client
For those of us who want access to this sweet trove of zero hop messages
This commit is contained in:
@ -227,6 +227,14 @@ class Client:
|
||||
"""List[:class:`.Emoji`]: The emojis that the connected client has."""
|
||||
return self._connection.emojis
|
||||
|
||||
@property
|
||||
def cached_messages(self):
|
||||
"""Sequence[:class:`~discord.Message`]: Read-only list of messages the connected client has cached.
|
||||
|
||||
.. versionadded:: 1.1.0
|
||||
"""
|
||||
return utils.SequenceProxy(self._connection._messages)
|
||||
|
||||
@property
|
||||
def private_channels(self):
|
||||
"""List[:class:`abc.PrivateChannel`]: The private channels that the connected client is participating on.
|
||||
|
Reference in New Issue
Block a user