summaryrefslogtreecommitdiff
path: root/data/rbot
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2007-02-06 11:34:17 +0000
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2007-02-06 11:34:17 +0000
commite7003544691b6166f90ba4fe5fa7acf906e48d1c (patch)
tree1580cd3b3cb149b4c69712cf08502475e4d99656 /data/rbot
parente935773b3e115d2d33e6d32f488578c650428ed2 (diff)
Suppress a couple of warnings
Diffstat (limited to 'data/rbot')
-rw-r--r--data/rbot/plugins/quiz.rb2
-rw-r--r--data/rbot/plugins/rss.rb5
2 files changed, 5 insertions, 2 deletions
diff --git a/data/rbot/plugins/quiz.rb b/data/rbot/plugins/quiz.rb
index 0d1d9ee6..21af8e1c 100644
--- a/data/rbot/plugins/quiz.rb
+++ b/data/rbot/plugins/quiz.rb
@@ -601,7 +601,7 @@ class QuizPlugin < Plugin
def cmd_top_number( m, params )
num = params[:number].to_i
- return unless 1..50 === num
+ return if num < 1 or num > 50
chan = m.channel
q = create_quiz( chan )
if q.nil?
diff --git a/data/rbot/plugins/rss.rb b/data/rbot/plugins/rss.rb
index 22a6dc18..08b2c775 100644
--- a/data/rbot/plugins/rss.rb
+++ b/data/rbot/plugins/rss.rb
@@ -341,7 +341,10 @@ class RSSFeedsPlugin < Plugin
def change_rss(m, params)
handle = params[:handle].downcase
feed = @feeds.fetch(handle, nil)
- return m.reply "No such feed with handle #{handle}" unless feed
+ unless feed
+ m.reply "No such feed with handle #{handle}"
+ return
+ end
case params[:what].intern
when :handle
new = params[:new].downcase