mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-18 03:15:41 +00:00
feat(Core/Characters): Replace DELETE + INSERT with REPLACE (#10862)
This commit is contained in:
committed by
GitHub
parent
624d41763a
commit
b6a07d38c0
@@ -561,12 +561,7 @@ void WorldSession::HandleCharCreateOpcode(WorldPacket& recvData)
|
||||
newChar->SaveToDB(characterTransaction, true, false);
|
||||
createInfo->CharCount++;
|
||||
|
||||
LoginDatabasePreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_DEL_REALM_CHARACTERS_BY_REALM);
|
||||
stmt->SetData(0, GetAccountId());
|
||||
stmt->SetData(1, realm.Id.Realm);
|
||||
trans->Append(stmt);
|
||||
|
||||
stmt = LoginDatabase.GetPreparedStatement(LOGIN_INS_REALM_CHARACTERS);
|
||||
LoginDatabasePreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_REP_REALM_CHARACTERS);
|
||||
stmt->SetData(0, createInfo->CharCount);
|
||||
stmt->SetData(1, GetAccountId());
|
||||
stmt->SetData(2, realm.Id.Realm);
|
||||
|
||||
Reference in New Issue
Block a user