mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-23 19:22:45 +01:00
We have to unAction or we get ugly replies
This commit is contained in:
parent
ba7b018078
commit
85355f5da7
@ -199,14 +199,16 @@ class Markov(callbacks.Privmsg):
|
||||
def die(self):
|
||||
self.q.die()
|
||||
|
||||
def tokenize(self, s):
|
||||
# XXX: Should this be smarter?
|
||||
return s.split()
|
||||
def tokenize(self, m):
|
||||
if ircmsgs.isAction(m):
|
||||
return ircmsgs.unAction(m).split()
|
||||
else:
|
||||
return m.args[1].split()
|
||||
|
||||
def doPrivmsg(self, irc, msg):
|
||||
channel = msg.args[0]
|
||||
if ircutils.isChannel(channel):
|
||||
words = self.tokenize(msg.args[1])
|
||||
words = self.tokenize(msg)
|
||||
words.insert(0, '\n')
|
||||
words.insert(0, '\n')
|
||||
words.append('\n')
|
||||
|
Loading…
Reference in New Issue
Block a user