chore: rename authorze_cache function name to check_authorization_cache

This commit is contained in:
zhanghongtong 2021-06-29 09:25:13 +08:00 committed by Rory Z
parent e1b0f44a8a
commit c9acf423ba
1 changed files with 2 additions and 2 deletions

View File

@ -46,11 +46,11 @@ authenticate(ClientInfo = #{zone := Zone}) ->
-> allow | deny).
authorize(ClientInfo, PubSub, Topic) ->
case emqx_acl_cache:is_enabled() of
true -> authorize_cache(ClientInfo, PubSub, Topic);
true -> check_authorization_cache(ClientInfo, PubSub, Topic);
false -> do_authorize(ClientInfo, PubSub, Topic)
end.
authorize_cache(ClientInfo, PubSub, Topic) ->
check_authorization_cache(ClientInfo, PubSub, Topic) ->
case emqx_acl_cache:get_acl_cache(PubSub, Topic) of
not_found ->
AclResult = do_authorize(ClientInfo, PubSub, Topic),