|
|
@@ -96,8 +96,8 @@ on_client_authenticate(ClientInfo, AuthResult) ->
|
|
|
|
|
|
case call_fold('client.authenticate', Req,
|
|
|
fun merge_responsed_bool/2) of
|
|
|
- {StopOrOk, #{result := Bool}} when is_boolean(Bool) ->
|
|
|
- Result = case Bool of true -> success; _ -> not_authorized end,
|
|
|
+ {StopOrOk, #{result := Result0}} when is_boolean(Result0) ->
|
|
|
+ Result = case Result0 of true -> success; _ -> not_authorized end,
|
|
|
{StopOrOk, AuthResult#{auth_result => Result, anonymous => false}};
|
|
|
_ ->
|
|
|
{ok, AuthResult}
|
|
|
@@ -116,8 +116,8 @@ on_client_check_acl(ClientInfo, PubSub, Topic, Result) ->
|
|
|
},
|
|
|
case call_fold('client.check_acl', Req,
|
|
|
fun merge_responsed_bool/2) of
|
|
|
- {StopOrOk, #{result := Bool}} when is_boolean(Bool) ->
|
|
|
- NResult = case Bool of true -> allow; _ -> deny end,
|
|
|
+ {StopOrOk, #{result := Result0}} when is_boolean(Result0) ->
|
|
|
+ NResult = case Result0 of true -> allow; _ -> deny end,
|
|
|
{StopOrOk, NResult};
|
|
|
_ -> {ok, Result}
|
|
|
end.
|