make empty blacklist not break everything

This commit is contained in:
iou1name 2018-05-18 17:25:18 -04:00
parent b8243374d4
commit 1dbdb1f546

View File

@ -54,7 +54,7 @@ class OppaiBot(irc.IRCClient):
or users alike.
"""
# More advanced logic is left as an exercise to the reader.
black_in_msg = [tag in message for tag in self.blacklist]
black_in_msg = [tag in message for tag in self.blacklist if tag]
if any(black_in_msg):
return