Merge pull request #11000 from thalesmg/fix-redis-ee-connector-on-stop-v50

fix(bridge_redis): fix `on_stop` `function_clause` error when there's no state
This commit is contained in:
Thales Macedo Garitezi 2023-06-09 14:52:06 -03:00 committed by GitHub
commit 9c057a718d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -1,6 +1,6 @@
{application, emqx_ee_connector, [
{description, "EMQX Enterprise connectors"},
{vsn, "0.1.13"},
{vsn, "0.1.14"},
{registered, []},
{applications, [
kernel,

View File

@ -44,7 +44,9 @@ on_start(InstId, #{command_template := CommandTemplate} = Config) ->
end.
on_stop(InstId, #{conn_st := RedisConnSt}) ->
emqx_connector_redis:on_stop(InstId, RedisConnSt).
emqx_connector_redis:on_stop(InstId, RedisConnSt);
on_stop(InstId, undefined = _State) ->
emqx_connector_redis:on_stop(InstId, undefined).
on_get_status(InstId, #{conn_st := RedisConnSt}) ->
emqx_connector_redis:on_get_status(InstId, RedisConnSt).