chore(src): fix dialyzer warnings (match values)
This commit is contained in:
parent
bd3bd906ca
commit
1504164933
|
@ -121,7 +121,7 @@ update_reg_info(NewRegInfo, Lwm2mState = #lwm2m_state{
|
|||
|
||||
UpdatedRegInfo = maps:merge(RegInfo, NewRegInfo),
|
||||
|
||||
case proplists:get_value(update_msg_publish_condition,
|
||||
_ = case proplists:get_value(update_msg_publish_condition,
|
||||
lwm2m_coap_responder:options(), contains_object_list) of
|
||||
always ->
|
||||
send_to_broker(<<"update">>, #{<<"data">> => UpdatedRegInfo}, Lwm2mState);
|
||||
|
|
|
@ -167,7 +167,7 @@ do_publish(_ClientId, [], _Qos, _Retain, _Payload) ->
|
|||
do_publish(ClientId, Topics, Qos, Retain, Payload) ->
|
||||
MsgIds = lists:map(fun(Topic) ->
|
||||
Msg = emqx_message:make(ClientId, Qos, Topic, Payload),
|
||||
emqx_mgmt:publish(Msg#message{flags = #{retain => Retain}}),
|
||||
_ = emqx_mgmt:publish(Msg#message{flags = #{retain => Retain}}),
|
||||
emqx_guid:to_hexstr(Msg#message.id)
|
||||
end, Topics),
|
||||
{ok, MsgIds}.
|
||||
|
|
|
@ -237,11 +237,11 @@ import_resources_and_rules(Resources, Rules, FromVersion)
|
|||
<<"url">> => URL,
|
||||
<<"verify">> => true},
|
||||
NResource = Resource#{<<"config">> := NConfig},
|
||||
import_resource(NResource),
|
||||
{ok, _Resource} = import_resource(NResource),
|
||||
NHeaders = maps:put(<<"content-type">>, ContentType, Headers),
|
||||
[{ID, #{headers => NHeaders, method => Method}} | Acc];
|
||||
(Resource, Acc) ->
|
||||
import_resource(Resource),
|
||||
{ok, _Resource} = import_resource(Resource),
|
||||
Acc
|
||||
end, [], Resources),
|
||||
lists:foreach(fun(#{<<"actions">> := Actions} = Rule) ->
|
||||
|
|
|
@ -407,8 +407,8 @@ delete_resource_type(Type) ->
|
|||
init([]) ->
|
||||
%% Enable stats timer
|
||||
ok = emqx_stats:update_interval(rule_registery_stats, fun update_stats/0),
|
||||
ets:new(?KV_TAB, [named_table, set, public, {write_concurrency, true},
|
||||
{read_concurrency, true}]),
|
||||
_TableId = ets:new(?KV_TAB, [named_table, set, public, {write_concurrency, true},
|
||||
{read_concurrency, true}]),
|
||||
{ok, #{}}.
|
||||
|
||||
handle_call({add_rules, Rules}, _From, State) ->
|
||||
|
|
|
@ -30,7 +30,7 @@ start(_StartType, _StartArgs) ->
|
|||
translate_env(),
|
||||
{ok, Sup} = emqx_web_hook_sup:start_link(),
|
||||
{ok, PoolOpts} = application:get_env(?APP, pool_opts),
|
||||
ehttpc_sup:start_pool(?APP, PoolOpts),
|
||||
{ok, _Pid} = ehttpc_sup:start_pool(?APP, PoolOpts),
|
||||
emqx_web_hook:register_metrics(),
|
||||
emqx_web_hook:load(),
|
||||
{ok, Sup}.
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
start(_Type, _Args) ->
|
||||
% the configs for emqx_modules is so far still in emqx application
|
||||
% Ensure it's loaded
|
||||
application:load(emqx),
|
||||
_ = application:load(emqx),
|
||||
{ok, Pid} = emqx_mod_sup:start_link(),
|
||||
ok = emqx_modules:load(),
|
||||
emqx_ctl:register_command(modules, {emqx_modules, cli}, []),
|
||||
|
|
Loading…
Reference in New Issue