fix(emqx_listeners): Dialyzer warnings

This commit is contained in:
Zaiming Shi 2020-11-06 13:49:29 +01:00
parent 7a39470200
commit f3d973689b
1 changed files with 2 additions and 2 deletions

View File

@ -124,10 +124,10 @@ restart_listener(tcp, ListenOn, _Options) ->
restart_listener(Proto, ListenOn, _Options) when Proto == ssl; Proto == tls ->
esockd:reopen('mqtt:ssl', ListenOn);
restart_listener(Proto, ListenOn, Options) when Proto == http; Proto == ws ->
cowboy:stop_listener(ws_name('mqtt:ws', ListenOn)),
_ = cowboy:stop_listener(ws_name('mqtt:ws', ListenOn)),
start_listener(Proto, ListenOn, Options);
restart_listener(Proto, ListenOn, Options) when Proto == https; Proto == wss ->
cowboy:stop_listener(ws_name('mqtt:wss', ListenOn)),
_ = cowboy:stop_listener(ws_name('mqtt:wss', ListenOn)),
start_listener(Proto, ListenOn, Options);
restart_listener(Proto, ListenOn, _Opts) ->
esockd:reopen(Proto, ListenOn).