summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2009-01-04 22:02:07 +0100
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2009-01-04 22:02:42 +0100
commiteaaea4319b21e4ddb4e3077f74255f3f0082122d (patch)
treebad2c838be8e5f576aab771990e4f78a1f3ae8c6
parentcfe6ef6b8bd9f972e5887f3d239206555ed2d06d (diff)
del.icio.us plugin: bailout early if not configured
-rw-r--r--data/rbot/plugins/delicious.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/data/rbot/plugins/delicious.rb b/data/rbot/plugins/delicious.rb
index 61ba0091..c2ab7d5d 100644
--- a/data/rbot/plugins/delicious.rb
+++ b/data/rbot/plugins/delicious.rb
@@ -62,6 +62,10 @@ class DeliciousPlugin < Plugin
def event_url_added(url, options = {})
debug("called with #{url}, #{options.inspect}")
+ if @bot.config['delicious.user'].empty?
+ debug "del.icio.us plugin not configured, skipping"
+ return
+ end
opts = Hash.new
opts[:description] = options[:title] || options[:info] || url
opts[:extended] = options[:extra] if options[:extra]