From: Badlop Date: Mon, 25 Jan 2010 18:32:45 +0000 (+0000) Subject: Support in ejabberdctl help command names with old - characters. X-Git-Tag: v2.1.3~73 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1b1a0d7ed35ae3bbea1236cbf031432dd5bc7258;p=ejabberd Support in ejabberdctl help command names with old - characters. SVN Revision: 2924 --- diff --git a/src/ejabberd_ctl.erl b/src/ejabberd_ctl.erl index 46871bd01..aee1a011f 100644 --- a/src/ejabberd_ctl.erl +++ b/src/ejabberd_ctl.erl @@ -189,8 +189,9 @@ process(["help" | Mode]) -> ["help"] -> print_usage_help(MaxC, ShCode), ?STATUS_SUCCESS; - [CommandString | _] -> - print_usage_commands(CommandString, MaxC, ShCode), + [CmdString | _] -> + {ok, CmdStringU, _} = regexp:gsub(CmdString, "-", "_"), + print_usage_commands(CmdStringU, MaxC, ShCode), ?STATUS_SUCCESS end;