mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Workaround for Markov wonkiness.
This commit is contained in:
parent
4923fc4a6c
commit
25281d7476
@ -123,6 +123,7 @@ class Markov(plugins.ChannelDBHandler, callbacks.Privmsg):
|
|||||||
data kept on <channel> (which is only necessary if not sent in the
|
data kept on <channel> (which is only necessary if not sent in the
|
||||||
channel itself).
|
channel itself).
|
||||||
"""
|
"""
|
||||||
|
argsCopy = args[:]
|
||||||
channel = privmsgs.getChannel(msg, args)
|
channel = privmsgs.getChannel(msg, args)
|
||||||
db = self.getDb(channel)
|
db = self.getDb(channel)
|
||||||
cursor = db.cursor()
|
cursor = db.cursor()
|
||||||
@ -154,7 +155,7 @@ class Markov(plugins.ChannelDBHandler, callbacks.Privmsg):
|
|||||||
break
|
break
|
||||||
words.append(word)
|
words.append(word)
|
||||||
if len(words) < self._minMarkovLength:
|
if len(words) < self._minMarkovLength:
|
||||||
self.markov(irc, msg, args)
|
self.markov(irc, msg, argsCopy)
|
||||||
else:
|
else:
|
||||||
irc.reply(' '.join(words))
|
irc.reply(' '.join(words))
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user