summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 7fc7d725c..0a571b3f2 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -75,6 +75,8 @@
const short awayLimitTimer = 60;
+typedef std::map<int, Guild*>::const_iterator GuildMapCIter;
+
LocalPlayer *player_node = nullptr;
extern std::list<BeingCacheEntry*> beingInfoCache;
@@ -903,8 +905,7 @@ void LocalPlayer::inviteToGuild(Being *const being)
// TODO: Allow user to choose which guild to invite being to
// For now, just invite to the first guild you have permissions to invite with
- for (std::map<int, Guild*>::const_iterator itr = mGuilds.begin(),
- itr_end = mGuilds.end(); itr != itr_end; ++itr)
+ FOR_EACH (GuildMapCIter, itr, mGuilds)
{
if (itr->second && checkInviteRights(itr->second->getName()))
{