1
0
Fork 0
mirror of synced 2024-06-03 11:14:33 +12:00

Handle no server settings

This commit is contained in:
phxntxm 2017-03-22 22:21:59 -05:00
parent 788743de25
commit 13f2b89e81

View file

@ -77,6 +77,9 @@ class Raffle:
self.bot.loop.create_task(utils.remove_content('raffles', raffle_id))
server_settings = await utils.get_content('server_settings', str(server.id))
if server_settings is None:
channel = self.bot.get_channel(server.id)
else:
channel_id = server_settings.get('notification_channel', server.id)
channel = self.bot.get_channel(channel_id)
try: