1
0
Fork 0
mirror of synced 2024-06-02 18:54:33 +12:00

Fixed the error for double on/off

This commit is contained in:
Phxntxm 2016-07-10 13:39:22 -05:00
parent 0d00cf1685
commit 2c07b3c32d

View file

@ -118,7 +118,7 @@ class Twitch:
await self.bot.say("I do not have your twitch URL added {}. You can save your twitch url with !twitch add".format(ctx.message.author.mention)) await self.bot.say("I do not have your twitch URL added {}. You can save your twitch url with !twitch add".format(ctx.message.author.mention))
config.closeConnection() config.closeConnection()
return return
elif result == "1": elif result['notifications_on']:
await self.bot.say("What do you want me to do, send two notifications? Not gonna happen {}".format(ctx.message.author.mention)) await self.bot.say("What do you want me to do, send two notifications? Not gonna happen {}".format(ctx.message.author.mention))
config.closeConnection() config.closeConnection()
return return
@ -139,7 +139,7 @@ class Twitch:
await self.bot.say("I do not have your twitch URL added {}. You can save your twitch url with !twitch add".format(ctx.message.author.mention)) await self.bot.say("I do not have your twitch URL added {}. You can save your twitch url with !twitch add".format(ctx.message.author.mention))
config.closeConnection() config.closeConnection()
return return
elif result == "0": elif not result['notifications_on']:
await self.bot.say("I am already set to not notify if you go live! Pay attention brah {}".format(ctx.message.author.mention)) await self.bot.say("I am already set to not notify if you go live! Pay attention brah {}".format(ctx.message.author.mention))
config.closeConnection() config.closeConnection()
return return