From 63231ef03396b31eadf20acac9ded942fdee523f Mon Sep 17 00:00:00 2001 From: Rapptz Date: Tue, 15 Aug 2017 22:37:39 -0400 Subject: Remove reason keyword argument from message deletion. Apparently this is unsupported. Affected functions include: * abc.Messageable.send * Message.delete * TextChannel.delete_messages * TextChannel.purge --- discord/message.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'discord/message.py') diff --git a/discord/message.py b/discord/message.py index 273da86a..e8bb4af2 100644 --- a/discord/message.py +++ b/discord/message.py @@ -475,7 +475,7 @@ class Message: return '{0.author.name} started a call \N{EM DASH} Join the call.'.format(self) @asyncio.coroutine - def delete(self, *, reason=None): + def delete(self): """|coro| Deletes the message. @@ -484,11 +484,6 @@ class Message: delete other people's messages, you need the :attr:`~Permissions.manage_messages` permission. - Parameters - ------------ - reason: Optional[str] - The reason for deleting this message. Shows up on the audit log. - Raises ------ Forbidden @@ -496,7 +491,7 @@ class Message: HTTPException Deleting the message failed. """ - yield from self._state.http.delete_message(self.channel.id, self.id, reason=reason) + yield from self._state.http.delete_message(self.channel.id, self.id) @asyncio.coroutine def edit(self, **fields): -- cgit v1.2.3