fix(emqx_conf): throw exception on clusetr_call falure

Not all callers handle error, some even ignore errors!
This commit is contained in:
Zaiming (Stone) Shi 2022-06-11 16:22:02 +02:00
parent 186e26e417
commit 0e06e4acaa
1 changed files with 4 additions and 1 deletions

View File

@ -223,7 +223,10 @@ check_cluster_rpc_result(Result) ->
Res; Res;
%% all MFA return not ok or {ok, term()}. %% all MFA return not ok or {ok, term()}.
{error, Error} -> {error, Error} ->
Error %% a lot of the callers do not handle
%% this error return, some even ignore
%% throw here to ensure the code will not proceed
erlang:throw(Error)
end. end.
%% Only gen hot_conf schema, not all configuration fields. %% Only gen hot_conf schema, not all configuration fields.