# When looking for words we separate them with
# arbitrary whitespace, not whatever they came with
pre = words.map { |w| Regexp.escape(w)}.join("\\s+")
- return Regexp.new("\\b#{pre}\\b", true)
+ pre << '\b' if pre.match(/\b$/)
+ pre = '\b' + pre if pre.match(/^\b/)
+ return Regexp.new(pre, true)
end
def facts(m, params)
reply << short_fact(f)
}
end
- m.reply reply.join(". "), :split_at => /\s+--\s+/
+ m.reply reply.join(". "), :split_at => /\[\d+\/\d+\] /, :purge_split => false
end
end