summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2009-02-15 22:43:44 +0100
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2009-02-15 22:43:44 +0100
commite3c929ff7f3e2491e7718e1da817d9de83b7bf1b (patch)
tree6719f9ff6ade44b9eb8ace3aedbd17b6978fd93d
parent02b6ba58b1edf5e3813ae3f4c4192e3ea54b33e6 (diff)
dictclient: put the Ruby/DICT URL in the LoadError message
This should help people find the right package.
-rw-r--r--data/rbot/plugins/dictclient.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/data/rbot/plugins/dictclient.rb b/data/rbot/plugins/dictclient.rb
index 903b3f1e..5b3bc631 100644
--- a/data/rbot/plugins/dictclient.rb
+++ b/data/rbot/plugins/dictclient.rb
@@ -15,7 +15,11 @@
# requires Ruby/DICT <http://www.caliban.org/ruby/ruby-dict.shtml>
-require 'dict'
+begin
+ require 'dict'
+rescue LoadError
+ raise LoadError, "Ruby/DICT not found, grab it from http://www.caliban.org/ruby/ruby-dict.shtml"
+end
class ::String
# Returns a new string truncated to length 'to'