diff --git a/lolbot.py b/lolbot.py index a01e883..7e41f5d 100644 --- a/lolbot.py +++ b/lolbot.py @@ -213,8 +213,8 @@ class LolBot(SingleServerIRCBot): self.quiz += 1 self.tip = 0 self.question = random.choice(self.qb) - print(str(self.question.question)) - self.connection.notice(self.channel, "Question %s: %s" % (self.quiz, str(self.question.question))) + print(self.question.question) + self.connection.notice(self.channel, "Question %s: %s" % (self.quiz, self.question.question)) def quiz_tip(self): if len(self.question.tip) > self.tip: @@ -315,10 +315,10 @@ class LolBot(SingleServerIRCBot): elif cmd == 'ask': if self.quiz: c.notice(self.channel, "Quiz is running. Use halt or quit to stop.") - c.notice(self.channel, str(self.question.question)) + c.notice(self.channel, self.question.question) elif isinstance(self.question, Question): c.notice(self.channel, "There is an unanswered question.") - c.notice(self.channel, str(self.question.question)) + c.notice(self.channel, self.question.question) else: self.start_quiz(nick) @@ -408,7 +408,7 @@ class LolBot(SingleServerIRCBot): try: (options, args) = getopt.getopt(sys.argv[1:], 'hc:s:p:j:n:d:', ['help', 'config=', 'server=', 'port=', 'join=', 'nick=', 'database=', ]) except getopt.GetoptError as err: - print(str(err)) + print(err) LolBot.usage() sys.exit(2)