Handle if the channel returned is None
This commit is contained in:
parent
99ac6fdd6c
commit
90598f26bf
|
@ -65,6 +65,8 @@ class Twitch:
|
|||
else:
|
||||
channel_id = int(s_id)
|
||||
channel = server.get_channel(channel_id)
|
||||
if channel is None:
|
||||
continue
|
||||
try:
|
||||
await channel.send("{} has just gone live! View their stream at <{}>".format(member.display_name, data['twitch_url']))
|
||||
except discord.Forbidden:
|
||||
|
|
Loading…
Reference in a new issue