diff options
author | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2006-12-22 16:38:17 +0000 |
---|---|---|
committer | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2006-12-22 16:38:17 +0000 |
commit | 7b3fba591a635ac86109e701705a7d875833c888 (patch) | |
tree | a8bde882ec096167bef78e51b59b585717b6dd3b /data/rbot | |
parent | 1686b5316059bf3f859dd01c48c4bacae6524f5b (diff) |
Only react on PrivMessage in salut and quiz
Diffstat (limited to 'data/rbot')
-rw-r--r-- | data/rbot/plugins/quiz.rb | 1 | ||||
-rw-r--r-- | data/rbot/plugins/salut.rb | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/data/rbot/plugins/quiz.rb b/data/rbot/plugins/quiz.rb index 04a869be..73f96589 100644 --- a/data/rbot/plugins/quiz.rb +++ b/data/rbot/plugins/quiz.rb @@ -262,6 +262,7 @@ class QuizPlugin < Plugin # def listen( m ) return unless @quizzes.has_key?( m.channel.to_s ) + return unless m.kind_of?(PrivMessage) q = @quizzes[m.channel.to_s] return if q.question == nil diff --git a/data/rbot/plugins/salut.rb b/data/rbot/plugins/salut.rb index 1ad6540a..6b16a745 100644 --- a/data/rbot/plugins/salut.rb +++ b/data/rbot/plugins/salut.rb @@ -69,6 +69,7 @@ class SalutPlugin < Plugin end
def listen(m)
+ return unless m.kind_of?(PrivMessage)
if @bot.config['salut.address_only']
return unless m.address? or m.message =~ /#{Regexp.escape(@bot.nick)}/
end
|