mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 10:55:43 +00:00
chore(Core/Player): Small optimization in the IsInWhisperWhiteList() … (#13026)
...function.
This commit is contained in:
@@ -15515,9 +15515,13 @@ void Player::_SaveInstanceTimeRestrictions(CharacterDatabaseTransaction trans)
|
||||
|
||||
bool Player::IsInWhisperWhiteList(ObjectGuid guid)
|
||||
{
|
||||
for (WhisperListContainer::const_iterator itr = WhisperList.begin(); itr != WhisperList.end(); ++itr)
|
||||
if (*itr == guid)
|
||||
for (auto const& itr : WhisperList)
|
||||
{
|
||||
if (itr == guid)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user