From 8dd2a6a97c60709ee0c52d709d5e371fc0675722 Mon Sep 17 00:00:00 2001 From: reality Date: Wed, 24 Jul 2013 22:27:50 +0000 Subject: [PATCH] setconfig prefix modules [#520] --- modules/admin/commands.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/admin/commands.js b/modules/admin/commands.js index 9ca3d0d..71b716c 100644 --- a/modules/admin/commands.js +++ b/modules/admin/commands.js @@ -185,9 +185,10 @@ var commands = function(dbot) { event.reply(dbot.t("config_array", { "alternate": "pushconfig" })); } } else { - topConfigPath = configPath.split('.')[0]; - if(_.has(dbot.config.modules, topConfigPath)) { + configPath = configPath.split('.'); + if(_.has(dbot.config.modules, configPath[0])) { configPath.splice(0, 0, 'modules'); + configPath = configPath.join('.'); event.params[1] = configPath.join('.'); this.commands['~showconfig'](event); return;