Core/DBLayer: Prevent using prepared statements on wrong database

This commit is contained in:
Shauren
2019-07-27 01:00:37 +02:00
parent 1dcbceba81
commit e8e89f58fb
102 changed files with 604 additions and 577 deletions

View File

@@ -559,7 +559,7 @@ void ReputationMgr::SaveToDB(SQLTransaction& trans)
{
if (itr->second.needSave)
{
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_REPUTATION_BY_FACTION);
CharacterDatabasePreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_REPUTATION_BY_FACTION);
stmt->setUInt64(0, _player->GetGUID().GetCounter());
stmt->setUInt16(1, uint16(itr->second.ID));
trans->Append(stmt);