|
@ -1062,6 +1062,17 @@ class Client: |
|
|
HTTPException |
|
|
HTTPException |
|
|
Purging the messages failed. |
|
|
Purging the messages failed. |
|
|
|
|
|
|
|
|
|
|
|
Examples |
|
|
|
|
|
--------- |
|
|
|
|
|
|
|
|
|
|
|
Deleting bot's messages :: |
|
|
|
|
|
|
|
|
|
|
|
def is_me(m): |
|
|
|
|
|
return m.author == client.user |
|
|
|
|
|
|
|
|
|
|
|
deleted = await client.purge_from(channel, limit=100, check=is_me) |
|
|
|
|
|
await client.send_message(channel, 'Deleted {} message(s)'.format(len(deleted))) |
|
|
|
|
|
|
|
|
Returns |
|
|
Returns |
|
|
-------- |
|
|
-------- |
|
|
list |
|
|
list |
|
|