From a4cb71b64e9a3f5d8861f2b77cc59588e56a319e Mon Sep 17 00:00:00 2001 From: Rapptz Date: Fri, 27 Nov 2020 03:31:10 -0500 Subject: [PATCH] Fix Message.to_reference from the MessageReference changes --- discord/message.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/discord/message.py b/discord/message.py index 39d9a22bc..ddcb7257d 100644 --- a/discord/message.py +++ b/discord/message.py @@ -311,7 +311,9 @@ class MessageReference: :class:`MessageReference` A reference to the message. """ - return cls(message._state, message_id=message.id, channel_id=message.channel.id, guild_id=getattr(message.guild, 'id', None)) + self = cls(message_id=message.id, channel_id=message.channel.id, guild_id=getattr(message.guild, 'id', None)) + self._state = message._state + return self @property def cached_message(self):