Print command's reply and newline only when there's something to print.

SVN Revision: 2806
This commit is contained in:
Badlop 2009-12-11 20:04:36 +00:00
parent b9e57a341d
commit d24449488c
1 changed files with 6 additions and 2 deletions

View File

@ -197,8 +197,12 @@ process(["help" | Mode]) ->
process(Args) ->
AccessCommands = get_accesscommands(),
{String, Code} = process2(Args, AccessCommands),
io:format(String),
io:format("\n"),
case String of
[] -> ok;
_ ->
io:format(String),
io:format("\n")
end,
Code.
%% @spec (Args::[string()], AccessCommands) -> {String::string(), Code::integer()}