markov: ensure messages are cleaned before learning and replying.
authorSpencer Rinehart <anubis@overthemonkey.com>
Tue, 3 Mar 2009 12:33:17 +0000 (07:33 -0500)
committerSpencer Rinehart <anubis@overthemonkey.com>
Tue, 3 Mar 2009 16:39:56 +0000 (11:39 -0500)
commit10ae83bef9c81cef32639b07d2a30f9ebfdc6440
tree508b0d3613a49150068230aaedf06233eefa5f9e
parent229f8b290e798e6f5af8d7be22d2e6c614a17fa1
markov: ensure messages are cleaned before learning and replying.

Lines that began with or ended with spaces were breaking the learning
thread.  The call to clean_str was moved down into learn_line (and
random_markov) so that all messages, including those being learned from
files, get cleaned.
data/rbot/plugins/markov.rb