]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - lib/rbot/core/config.rb
plugins: refactor plugin scanning
[user/henk/code/ruby/rbot.git] / lib / rbot / core / config.rb
index fc99fd8c961f5de8dae44dc89050362337a5ea0e..d887855d33614350b554cdc94d21e9b7903f0ed5 100644 (file)
@@ -77,7 +77,7 @@ class ConfigModule < CoreBotModule
     if cfs.empty?
       m.reply _("no config key found matching %{r}") % { :r => params[:rx].to_s}
     else
-      m.reply _("possible keys: %{kl}") % { :kl => cfs.map { |c| c.first}.join(', ') } if cfs.length > 1
+      m.reply _("possible keys: %{kl}") % { :kl => cfs.map { |c| c.first}.sort.join(', ') } if cfs.length > 1
       m.reply cfs.map { |c| c.join(': ') }.join("\n")
     end
   end
@@ -181,6 +181,7 @@ class ConfigModule < CoreBotModule
 
   def bot_nick(m, param)
     @bot.nickchg(param[:nick])
+    @bot.wanted_nick = param[:nick]
   end
 
   def bot_status(m, param)