Browse Source

Fix _get_message returning the message cache.

pull/2327/head
Lorenzo 6 years ago
committed by Danny
parent
commit
828e8189d3
  1. 2
      discord/state.py

2
discord/state.py

@ -256,7 +256,7 @@ class ConnectionState:
self._private_channels_by_user.pop(channel.recipient.id, None)
def _get_message(self, msg_id):
return self._messages and utils.find(lambda m: m.id == msg_id, reversed(self._messages))
return utils.find(lambda m: m.id == msg_id, reversed(self._messages)) if self._messages else None
def _add_guild_from_data(self, guild):
guild = Guild(data=guild, state=self)

Loading…
Cancel
Save