mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-24 22:26:22 +00:00
feat: Added logs_ip_action + more (#1157)
This commit is contained in:
committed by
Francesco Borzì
parent
6750fd5a73
commit
2a71b2a666
@@ -8,6 +8,7 @@
|
||||
#include "DatabaseEnv.h"
|
||||
#include "ObjectAccessor.h"
|
||||
#include "Player.h"
|
||||
#include "ScriptMgr.h"
|
||||
#include "Util.h"
|
||||
#include "SHA1.h"
|
||||
#include "WorldSession.h"
|
||||
@@ -149,10 +150,16 @@ namespace AccountMgr
|
||||
std::string username;
|
||||
|
||||
if (!GetName(accountId, username))
|
||||
{
|
||||
sScriptMgr->OnFailedPasswordChange(accountId);
|
||||
return AOR_NAME_NOT_EXIST; // account doesn't exist
|
||||
}
|
||||
|
||||
if (utf8length(newPassword) > MAX_ACCOUNT_STR)
|
||||
{
|
||||
sScriptMgr->OnFailedEmailChange(accountId);
|
||||
return AOR_PASS_TOO_LONG;
|
||||
}
|
||||
|
||||
normalizeString(username);
|
||||
normalizeString(newPassword);
|
||||
@@ -164,6 +171,7 @@ namespace AccountMgr
|
||||
|
||||
LoginDatabase.Execute(stmt);
|
||||
|
||||
sScriptMgr->OnPasswordChange(accountId);
|
||||
return AOR_OK;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user