diff --git a/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp b/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp index 6aa90f92f1..a8232ea5d1 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp @@ -202,13 +202,13 @@ public: break; const Position &randomPos = PosWrap[positions[i]]; - auto candIt = candidates.begin(); + auto itr = candidates.begin(); if (candidates.size() > 1) - std::advance(candIt, urand(0, candidates.size() - 1)); + std::advance(itr, urand(0, candidates.size() - 1)); - Unit *target = *candIt; - candIt = candidates.erase(candIt); + Unit *target = *itr; + candidates.erase(itr); float dx = randomPos.GetPositionX() - target->GetPositionX(); float dy = randomPos.GetPositionY() - target->GetPositionY();