mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-06-07 12:18:59 +00:00
Don't silently swallow ValueError thrown from on_channel_delete.
This commit is contained in:
parent
e08b278c52
commit
56a71e3166
@ -226,9 +226,10 @@ class ConnectionState(object):
|
||||
channel = utils.find(lambda c: c.id == channel_id, server.channels)
|
||||
try:
|
||||
server.channels.remove(channel)
|
||||
self.dispatch('channel_delete', channel)
|
||||
except ValueError:
|
||||
return
|
||||
else:
|
||||
self.dispatch('channel_delete', channel)
|
||||
|
||||
def handle_channel_update(self, data):
|
||||
server = self._get_server(data.get('guild_id'))
|
||||
|
Loading…
x
Reference in New Issue
Block a user