Fixed TTS Setting command

This commit is contained in:
Alex Orid 2020-10-15 15:32:17 -04:00
parent 7205964c3c
commit 7aa6c55863

View File

@ -13,8 +13,10 @@ class CommandTTS(AbstractCommand, metaclass=ABCMeta):
def do_command(self, bot, twitch_message):
args = self.get_args(twitch_message.text)
if args[1] == "start":
bot.send_message("tts activated on #%s" % twitch_message.channel)
bot.tts_enabled = True
if twitch_message.sender.lower() == twitch_message.channel:
bot.send_message("tts activated on #%s" % twitch_message.channel)
bot.tts_enabled = True
elif args[1] == "stop":
bot.send_message("tts deactivated")
bot.tts_enabled = False
if twitch_message.sender.lower() == twitch_message.channel:
bot.send_message("tts activated on #%s" % twitch_message.channel)
bot.tts_enabled = False