ejabberd_admin: Fix *_config command result format

The 'reload_config' and 'dump_config' calls are expected to yield a
'rescode' result, which means they must return 'ok' (rather than a
tuple) on success.

Fixes #3170.
This commit is contained in:
Holger Weiss 2020-02-14 18:52:54 +01:00
parent 66a84b8d2b
commit e7c84b81b2
1 changed files with 2 additions and 2 deletions

View File

@ -554,7 +554,7 @@ registered_vhosts() ->
reload_config() ->
case ejabberd_config:reload() of
ok -> {ok, ""};
ok -> ok;
Err ->
Reason = ejabberd_config:format_error(Err),
{error, Reason}
@ -562,7 +562,7 @@ reload_config() ->
dump_config(Path) ->
case ejabberd_config:dump(Path) of
ok -> {ok, ""};
ok -> ok;
Err ->
Reason = ejabberd_config:format_error(Err),
{error, Reason}