summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Kretschmann <markey@web.de>2006-08-29 16:46:57 +0000
committerMark Kretschmann <markey@web.de>2006-08-29 16:46:57 +0000
commit617b282bcd157896ccf630415b29022acd2aca62 (patch)
tree6b963713b5afcc5afec6e524289352b68fbba0ad
parenta3dc8d973b49d6a4bf1446093c194aed5f69916f (diff)
* Fix: @commands was not initialized on a fresh registry.
* Remove legacy registry migration code.
-rw-r--r--data/rbot/plugins/script.rb11
1 files changed, 1 insertions, 10 deletions
diff --git a/data/rbot/plugins/script.rb b/data/rbot/plugins/script.rb
index 431b5246..bf8182ce 100644
--- a/data/rbot/plugins/script.rb
+++ b/data/rbot/plugins/script.rb
@@ -18,18 +18,9 @@ class ScriptPlugin < Plugin
super
if @registry.has_key?(:commands)
@commands = @registry[:commands]
- end
-
- if @commands.nil?
+ else
@commands = Hash.new
end
-
- # Migrate old Hash to new:
- @commands.each_pair do |name, cmd|
- unless cmd.instance_of?( Command )
- @commands[name] = Command.new( cmd, 'unknown hacker', 'somedate', '#somechan' )
- end
- end
end