summaryrefslogtreecommitdiff
path: root/rbot/plugins/quotes.rb
diff options
context:
space:
mode:
authorTom Gilbert <tom@linuxbrit.co.uk>2005-07-16 01:18:13 +0000
committerTom Gilbert <tom@linuxbrit.co.uk>2005-07-16 01:18:13 +0000
commita08b4def5c276df964ae2a8d9c3f661593d757e6 (patch)
treecd563b11ab095bd364036d14bc28fb5fb4c065a8 /rbot/plugins/quotes.rb
parent71e16adb8a62a78fc1e8cdcc6776b6cd84fbe758 (diff)
various fixes by me, plus most of Rene's patch (#1).
Diffstat (limited to 'rbot/plugins/quotes.rb')
-rw-r--r--rbot/plugins/quotes.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/rbot/plugins/quotes.rb b/rbot/plugins/quotes.rb
index 072e352a..0e46b495 100644
--- a/rbot/plugins/quotes.rb
+++ b/rbot/plugins/quotes.rb
@@ -64,7 +64,7 @@ class QuotePlugin < Plugin
return 0 unless(@lists.has_key?(channel))
return 0 unless(@lists[channel].length > 0)
if(regexp)
- matches = @lists[channel].compact.find_all {|a| a.quote =~ /#{regexp}/ }
+ matches = @lists[channel].compact.find_all {|a| a.quote =~ /#{regexp}/i }
else
matches = @lists[channel].compact
end
@@ -73,7 +73,7 @@ class QuotePlugin < Plugin
def searchquote(source, channel, regexp)
return nil unless(@lists.has_key?(channel))
return nil unless(@lists[channel].length > 0)
- matches = @lists[channel].compact.find_all {|a| a.quote =~ /#{regexp}/ }
+ matches = @lists[channel].compact.find_all {|a| a.quote =~ /#{regexp}/i }
if(matches.length > 0)
return matches[rand(matches.length)], @lists[channel].length - 1
else