summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2010-11-19 15:54:42 +0000
committerSimon MacMullen <simon@rabbitmq.com>2010-11-19 15:54:42 +0000
commitf56bc4635a20113671874cdb1fa2af3f5c9487dc (patch)
treef53abc96d4fa15124a770e451ea880a08ad2e521
parent88913f8e9bc1145898f1e50f1315675e6b215e72 (diff)
downloadrabbitmq-server-f56bc4635a20113671874cdb1fa2af3f5c9487dc.tar.gz
Be consistent about refused return
-rw-r--r--src/rabbit_access_control.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rabbit_access_control.erl b/src/rabbit_access_control.erl
index 2dc8f172..30bcc9f3 100644
--- a/src/rabbit_access_control.erl
+++ b/src/rabbit_access_control.erl
@@ -112,8 +112,8 @@ check_user_pass_login(Username, Pass) ->
case lookup_user(Username) of
{ok, User} ->
case check_password(Pass, User#user.password_hash) of
- true -> {ok, User};
- _ -> refused
+ true -> {ok, User};
+ _ -> {refused, Username}
end;
{error, not_found} ->
{refused, Username}