lib/protonbot/bot_plugins.rb in protonbot-0.2.1 vs lib/protonbot/bot_plugins.rb in protonbot-0.2.2

- old
+ new

@@ -75,9 +75,10 @@ # Loads plugin from gem # @param gemname [String] Name of gem # @return [Bot] self def gem(gemname) if Gem.loaded_specs[gemname] + require gemname.gsub(/-/, '/') path = "#{Gem.loaded_specs[gemname].lib_dirs_glob.split(':')[0]}/" \ "#{gemname.gsub(/-/, '/')}/plugin.rb" if File.exist? path pl = pluginr(path) raise ProtonBot::PluginError, "`#{path}` did not return plugin!" unless