From 7aa6c558632dd5cf1f57d92e31bcc9dad1a82b90 Mon Sep 17 00:00:00 2001 From: Alex Orid Date: Thu, 15 Oct 2020 15:32:17 -0400 Subject: [PATCH] Fixed TTS Setting command --- commands/implemented/command_tts.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/commands/implemented/command_tts.py b/commands/implemented/command_tts.py index 4392cc5..305e1cf 100644 --- a/commands/implemented/command_tts.py +++ b/commands/implemented/command_tts.py @@ -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