Fix to show correctly the command that is unknown

This commit is contained in:
Badlop 2011-02-23 16:51:40 +01:00
parent eaa17dab90
commit 9a55ced505
1 changed files with 1 additions and 1 deletions

View File

@ -283,7 +283,7 @@ call_command([CmdString | Args], Auth, AccessCommands) ->
Command = list_to_atom(CmdStringU),
case ejabberd_commands:get_command_format(Command) of
{error, command_unknown} ->
{error, io_lib:format("Error: command ~p not known.", [hd(Args)])};
{error, io_lib:format("Error: command ~p not known.", [CmdString])};
{ArgsFormat, ResultFormat} ->
case (catch format_args(Args, ArgsFormat)) of
ArgsFormatted when is_list(ArgsFormatted) ->