aboutsummaryrefslogtreecommitdiff
path: root/discord/state.py
diff options
context:
space:
mode:
authorLilly Rose Berner <[email protected]>2021-06-29 01:03:59 +0200
committerGitHub <[email protected]>2021-06-28 19:03:59 -0400
commit6b1d46a1eac4a6fcd2607c50fda02ddb10a330a8 (patch)
treec77ca044866ca1ba9cb639cafd2ade8538ec41b0 /discord/state.py
parentDispatch thread_join when a thread is updated but not in cache (diff)
downloaddiscord.py-6b1d46a1eac4a6fcd2607c50fda02ddb10a330a8.tar.xz
discord.py-6b1d46a1eac4a6fcd2607c50fda02ddb10a330a8.zip
Set Message.guild from guild_id if unavailable through Message.channel
Diffstat (limited to 'discord/state.py')
-rw-r--r--discord/state.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/discord/state.py b/discord/state.py
index e87d1ab1..3afee473 100644
--- a/discord/state.py
+++ b/discord/state.py
@@ -1277,7 +1277,7 @@ class AutoShardedConnectionState(ConnectionState):
if new_guild is not None and new_guild is not msg.guild:
channel_id = msg.channel.id
channel = new_guild.get_channel(channel_id) or new_guild.get_thread(channel_id) or Object(id=channel_id)
- msg._rebind_channel_reference(channel)
+ msg._rebind_cached_references(new_guild, channel)
async def chunker(self, guild_id, query='', limit=0, presences=False, *, shard_id=None, nonce=None):
ws = self._get_websocket(guild_id, shard_id=shard_id)