aboutsummaryrefslogtreecommitdiff
path: root/src/web/ejabberd_web_admin.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/web/ejabberd_web_admin.erl')
-rw-r--r--src/web/ejabberd_web_admin.erl8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/web/ejabberd_web_admin.erl b/src/web/ejabberd_web_admin.erl
index cfbdbe746..d92f54efa 100644
--- a/src/web/ejabberd_web_admin.erl
+++ b/src/web/ejabberd_web_admin.erl
@@ -2539,7 +2539,7 @@ get_node(global, Node, ["update"], Query, Lang) ->
[?XC('h1', ?T("Update ") ++ atom_to_list(Node))] ++
case Res of
ok -> [?XREST("Submitted")];
- error -> [?XREST("Bad format")];
+ {error, ErrorText} -> [?XREST("Error: " ++ ErrorText)];
nothing -> []
end ++
[?XAE('form', [?XMLATTR('action', <<>>), ?XMLATTR('method', <<"post">>)],
@@ -2922,9 +2922,11 @@ node_update_parse_query(Node, Query) ->
{ok, _} ->
ok;
{error, Error} ->
- ?ERROR_MSG("~p~n", [Error]);
+ ?ERROR_MSG("~p~n", [Error]),
+ {error, io_lib:format("~p", [Error])};
{badrpc, Error} ->
- ?ERROR_MSG("~p~n", [Error])
+ ?ERROR_MSG("Bad RPC: ~p~n", [Error]),
+ {error, "Bad RPC: " ++ io_lib:format("~p", [Error])}
end;
_ ->
nothing