From b901dfee84de64360e685702900bc5ee605b7bf1 Mon Sep 17 00:00:00 2001 From: Robby- Date: Mon, 4 Nov 2013 02:59:16 +0100 Subject: [PATCH] ns_identify: When logging failures, also show the account name, and that it exists or not. --- modules/commands/ns_identify.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/commands/ns_identify.cpp b/modules/commands/ns_identify.cpp index ede1c381c..a26e35d8c 100644 --- a/modules/commands/ns_identify.cpp +++ b/modules/commands/ns_identify.cpp @@ -44,8 +44,9 @@ class NSIdentifyRequest : public IdentifyRequest { if (source.GetUser()) { - Log(LOG_COMMAND, source, cmd) << "and failed to identify"; - if (NickAlias::Find(GetAccount()) != NULL) + bool accountexists = NickAlias::Find(GetAccount()) != NULL; + Log(LOG_COMMAND, source, cmd) << "and failed to identify to" << (accountexists ? " " : " nonexistent ") << "account " << GetAccount(); + if (accountexists) { source.Reply(PASSWORD_INCORRECT); source.GetUser()->BadPassword();