25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-20 16:15:59 +01:00

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

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}