fix(emqx_router): return correct type from lookup_routes/1 (v2 schema)
This commit is contained in:
parent
4f341bef8b
commit
0db6b8dc54
|
@ -512,7 +512,7 @@ lookup_routes_v2(Topic) ->
|
||||||
case emqx_topic:wildcard(Topic) of
|
case emqx_topic:wildcard(Topic) of
|
||||||
true ->
|
true ->
|
||||||
Pat = #routeidx{entry = emqx_topic_index:make_key(Topic, '$1')},
|
Pat = #routeidx{entry = emqx_topic_index:make_key(Topic, '$1')},
|
||||||
[Dest || [Dest] <- ets:match(?ROUTE_TAB_FILTERS, Pat)];
|
[#route{topic = Topic, dest = Dest} || [Dest] <- ets:match(?ROUTE_TAB_FILTERS, Pat)];
|
||||||
false ->
|
false ->
|
||||||
lookup_route_tab(Topic)
|
lookup_route_tab(Topic)
|
||||||
end.
|
end.
|
||||||
|
|
Loading…
Reference in New Issue