From ab93b4cacfb71fc5de25be245ad7d8092de2131b Mon Sep 17 00:00:00 2001 From: David Vazgenovich Shakaryan Date: Mon, 14 Apr 2014 23:23:53 -0700 Subject: Minor bug fixes and improved admin module. --- dinobot.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dinobot.rb') diff --git a/dinobot.rb b/dinobot.rb index 09964ef..c62771b 100644 --- a/dinobot.rb +++ b/dinobot.rb @@ -106,7 +106,7 @@ module Dinobot case method.first when :say send(*method) if method.length == 3 - when :join, :part, :load_module, :unload_module + when :join, :part send(*method) if method.length == 2 end end @@ -144,7 +144,7 @@ module Dinobot load "#{mod}.rb" m = Dinobot.const_get(Dinobot.constants.find { |x| x.downcase == mod }) - @modules[mod] = m.new + @modules[mod] = m.new(self) puts "== Loaded module: #{mod} (#{m})" rescue LoadError, StandardError => e -- cgit v1.2.3-70-g09d2