]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - lib/rbot/botuser.rb
greed: refactor and prepare for more complete play
[user/henk/code/ruby/rbot.git] / lib / rbot / botuser.rb
index 8fa04fc54f47f21fe95eea61ce47cb5d04b7fb1f..4e93beb4cb39c3ab9661fd2992f0f95072b8f705 100644 (file)
@@ -24,7 +24,7 @@ require 'rbot/maskdb'
 #     }
 #   }
 # end
-# 
+#
 
 module Irc
 class Bot
@@ -90,8 +90,8 @@ class Bot
       #
       def initialize(cmd)
         cmdpath = sanitize_command_path(cmd).split('::')
-        seq = cmdpath.inject(["*"]) { |list, cmd|
-          list << (list.length > 1 ? list.last + "::" : "") + cmd
+        seq = cmdpath.inject(["*"]) { |list, cc|
+          list << (list.length > 1 ? list.last + "::" : "") + cc
         }
         @path = seq.map { |k|
           k.to_sym
@@ -461,7 +461,7 @@ class Bot
       # Adds a Netmask
       #
       def add_netmask(mask)
-        m = mask.to_irc_netmask(:server => nil,:force => true)
+        m = mask.to_irc_netmask
         @netmasks << m
         if self.autologin?
           Auth.manager.maskdb.add(self, m)