mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-14 04:02:53 -04:00
Core/DBLayer: Prevent using prepared statements on wrong database
This commit is contained in:
@@ -43,7 +43,7 @@ void SmartWaypointMgr::LoadFromDB()
|
||||
|
||||
waypoint_map.clear();
|
||||
|
||||
PreparedStatement* stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_SMARTAI_WP);
|
||||
WorldDatabasePreparedStatement* stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_SMARTAI_WP);
|
||||
PreparedQueryResult result = WorldDatabase.Query(stmt);
|
||||
|
||||
if (!result)
|
||||
@@ -112,7 +112,7 @@ void SmartAIMgr::LoadSmartAIFromDB()
|
||||
for (uint8 i = 0; i < SMART_SCRIPT_TYPE_MAX; i++)
|
||||
mEventMap[i].clear(); //Drop Existing SmartAI List
|
||||
|
||||
PreparedStatement* stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_SMART_SCRIPTS);
|
||||
WorldDatabasePreparedStatement* stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_SMART_SCRIPTS);
|
||||
PreparedQueryResult result = WorldDatabase.Query(stmt);
|
||||
|
||||
if (!result)
|
||||
|
||||
Reference in New Issue
Block a user