summaryrefslogtreecommitdiff
path: root/src/channels.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2013-06-26 17:01:33 -0400
committerattilamolnar <attilamolnar@hush.com>2013-08-04 16:08:57 +0200
commit8710724b5518ae9858309e548514f76e620a8459 (patch)
treecb4efb99580cb8957353848a9dc34d5a83ab172e /src/channels.cpp
parent36f93c0e7f8a980943237b0b28138ade86f5e573 (diff)
Change the syntax of FOREACH macros to be less dumb.
Diffstat (limited to 'src/channels.cpp')
-rw-r--r--src/channels.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/channels.cpp b/src/channels.cpp
index e9e2a3020..d82ad6c23 100644
--- a/src/channels.cpp
+++ b/src/channels.cpp
@@ -86,7 +86,7 @@ void Channel::SetTopic(User* u, const std::string& ntopic)
this->WriteChannel(u, "TOPIC %s :%s", this->name.c_str(), this->topic.c_str());
this->topicset = ServerInstance->Time();
- FOREACH_MOD(I_OnPostTopicChange,OnPostTopicChange(u, this, this->topic));
+ FOREACH_MOD(OnPostTopicChange, (u, this, this->topic));
}
Membership* Channel::AddUser(User* user)
@@ -120,7 +120,7 @@ void Channel::CheckDestroy()
/* kill the record */
if (iter != ServerInstance->chanlist->end())
{
- FOREACH_MOD(I_OnChannelDelete, OnChannelDelete(this));
+ FOREACH_MOD(OnChannelDelete, (this));
ServerInstance->chanlist->erase(iter);
}
@@ -355,7 +355,7 @@ void Channel::ForceJoin(User* user, const std::string* privs, bool bursting, boo
// Tell modules about this join, they have the chance now to populate except_list with users we won't send the JOIN (and possibly MODE) to
CUList except_list;
- FOREACH_MOD(I_OnUserJoin,OnUserJoin(memb, bursting, created_by_local, except_list));
+ FOREACH_MOD(OnUserJoin, (memb, bursting, created_by_local, except_list));
this->WriteAllExcept(user, false, 0, except_list, "JOIN :%s", this->name.c_str());
@@ -380,7 +380,7 @@ void Channel::ForceJoin(User* user, const std::string* privs, bool bursting, boo
this->UserList(user);
}
- FOREACH_MOD(I_OnPostJoin,OnPostJoin(memb));
+ FOREACH_MOD(OnPostJoin, (memb));
}
bool Channel::IsBanned(User* user)
@@ -465,7 +465,7 @@ void Channel::PartUser(User *user, std::string &reason)
{
Membership* memb = membiter->second;
CUList except_list;
- FOREACH_MOD(I_OnUserPart,OnUserPart(memb, reason, except_list));
+ FOREACH_MOD(OnUserPart, (memb, reason, except_list));
WriteAllExcept(user, false, 0, except_list, "PART %s%s%s", this->name.c_str(), reason.empty() ? "" : " :", reason.c_str());
@@ -520,7 +520,7 @@ void Channel::KickUser(User* src, User* victim, const std::string& reason, Membe
}
CUList except_list;
- FOREACH_MOD(I_OnUserKick,OnUserKick(src, memb, reason, except_list));
+ FOREACH_MOD(OnUserKick, (src, memb, reason, except_list));
WriteAllExcept(src, false, 0, except_list, "KICK %s %s :%s", name.c_str(), victim->nick.c_str(), reason.c_str());
@@ -696,7 +696,7 @@ void Channel::UserList(User *user)
prefixlist = this->GetPrefixChar(i->first);
nick = i->first->nick;
- FOREACH_MOD(I_OnNamesListItem, OnNamesListItem(user, i->second, prefixlist, nick));
+ FOREACH_MOD(OnNamesListItem, (user, i->second, prefixlist, nick));
/* Nick was nuked, a module wants us to skip it */
if (nick.empty())