From 91df762e93212958db487d8517addba1a63a4ddd Mon Sep 17 00:00:00 2001 From: danieldg Date: Sun, 13 Sep 2009 20:30:47 +0000 Subject: Membership* changes git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11697 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_invisible.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'src/modules/m_invisible.cpp') diff --git a/src/modules/m_invisible.cpp b/src/modules/m_invisible.cpp index 678b9cc49..7da3f2934 100644 --- a/src/modules/m_invisible.cpp +++ b/src/modules/m_invisible.cpp @@ -49,21 +49,21 @@ class InvisibleMode : public ModeHandler /* User appears to vanish or appear from nowhere */ for (UCListIter f = dest->chans.begin(); f != dest->chans.end(); f++) { - CUList *ulist = f->first->GetUsers(); + const UserMembList *ulist = (*f)->GetUsers(); char tb[MAXBUF]; - snprintf(tb,MAXBUF,":%s %s %s", dest->GetFullHost().c_str(), adding ? "PART" : "JOIN", f->first->name.c_str()); + snprintf(tb,MAXBUF,":%s %s %s", dest->GetFullHost().c_str(), adding ? "PART" : "JOIN", (*f)->name.c_str()); std::string out = tb; - std::string n = this->ServerInstance->Modes->ModeString(dest, f->first); + std::string n = this->ServerInstance->Modes->ModeString(dest, (*f)); - for (CUList::iterator i = ulist->begin(); i != ulist->end(); i++) + for (UserMembCIter i = ulist->begin(); i != ulist->end(); i++) { /* User only appears to vanish for non-opers */ if (IS_LOCAL(i->first) && !IS_OPER(i->first)) { i->first->Write(out); if (!n.empty() && !adding) - i->first->WriteServ("MODE %s +%s", f->first->name.c_str(), n.c_str()); + i->first->WriteServ("MODE %s +%s", (*f)->name.c_str(), n.c_str()); } } } @@ -186,7 +186,7 @@ void ModuleInvisible::OnUserQuit(User* user, const std::string &reason, const st if (parthandler) { for (UCListIter f = user->chans.begin(); f != user->chans.end(); f++) - to_leave.push_back(f->first->name); + to_leave.push_back((*f)->name); /* We cant do this neatly in one loop, as we are modifying the map we are iterating */ for (std::vector::iterator n = to_leave.begin(); n != to_leave.end(); n++) { @@ -236,9 +236,9 @@ void ModuleInvisible::WriteCommonFrom(User *user, Channel* channel, const char* va_end(argsPtr); snprintf(tb,MAXBUF,":%s %s",user->GetFullHost().c_str(), textbuffer); - CUList *ulist = channel->GetUsers(); + const UserMembList *ulist = channel->GetUsers(); - for (CUList::iterator i = ulist->begin(); i != ulist->end(); i++) + for (UserMembCIter i = ulist->begin(); i != ulist->end(); i++) { /* User only appears to vanish for non-opers */ if (IS_LOCAL(i->first) && IS_OPER(i->first)) -- cgit v1.2.3