fix: use parse_id
This commit is contained in:
parent
048f4724a9
commit
70978df5bb
|
@ -648,13 +648,8 @@ format_resource_data(added_channels, Channels, Result) ->
|
||||||
format_resource_data(K, V, Result) ->
|
format_resource_data(K, V, Result) ->
|
||||||
Result#{K => V}.
|
Result#{K => V}.
|
||||||
|
|
||||||
format_action(Action) ->
|
format_action(ActionId) ->
|
||||||
case string:split(Action, ":", all) of
|
element(2, emqx_bridge_v2:parse_id(ActionId)).
|
||||||
[_Prefix, _Type, Name | _] ->
|
|
||||||
Name;
|
|
||||||
_ ->
|
|
||||||
Action
|
|
||||||
end.
|
|
||||||
|
|
||||||
is_ok(ok) ->
|
is_ok(ok) ->
|
||||||
ok;
|
ok;
|
||||||
|
|
Loading…
Reference in New Issue