From ba719a896d9c7dca399223b3d8f2871a0b73adf6 Mon Sep 17 00:00:00 2001 From: Feng Lee Date: Wed, 13 Mar 2019 15:33:57 +0800 Subject: [PATCH] Call 'tokens/1' instead of 'words/1' --- src/emqx_topic.erl | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/emqx_topic.erl b/src/emqx_topic.erl index 6679b893f..7a75b8f23 100644 --- a/src/emqx_topic.erl +++ b/src/emqx_topic.erl @@ -157,11 +157,6 @@ levels(Topic) when is_binary(Topic) -> tokens(Topic) -> binary:split(Topic, <<"/">>, [global]). -%% @doc Split topic to tokens. --spec(tokens(topic()) -> list(binary())). -tokens(Topic) -> - binary:split(Topic, <<"/">>, [global]). - %% @doc Split Topic Path to Words -spec(words(topic()) -> words()). words(Topic) when is_binary(Topic) -> @@ -226,4 +221,3 @@ parse(Topic, Options = #{qos := QoS}) -> {Topic, Options#{rc => QoS}}; parse(Topic, Options) -> {Topic, Options}. -