# }
# }
# end
-#
+#
module Irc
class Bot
module Auth
Config.register Config::StringValue.new( 'auth.password',
- :default => 'rbotauth', :wizard => true,
+ :default => [*?a..?z,*?A..?Z,*?0..?9].sample(8).join, :wizard => true,
:on_change => Proc.new {|bot, v| bot.auth.botowner.password = v},
:desc => _('Password for the bot owner'))
Config.register Config::BooleanValue.new( 'auth.login_by_mask',
#
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