cmd_invite Fire the OnUserInvite event before announcing the invite

This commit is contained in:
Attila Molnar 2015-12-06 11:20:45 +01:00
parent 81215de4f0
commit f307c873e0

View File

@ -141,9 +141,10 @@ CmdResult CommandInvite::Handle (const std::vector<std::string>& parameters, Use
} }
} }
FOREACH_MOD(OnUserInvite, (user, u, c, timeout));
if (ServerInstance->Config->AnnounceInvites != ServerConfig::INVITE_ANNOUNCE_NONE) if (ServerInstance->Config->AnnounceInvites != ServerConfig::INVITE_ANNOUNCE_NONE)
c->WriteAllExceptSender(user, true, prefix, "NOTICE %s :*** %s invited %s into the channel", c->name.c_str(), user->nick.c_str(), u->nick.c_str()); c->WriteAllExceptSender(user, true, prefix, "NOTICE %s :*** %s invited %s into the channel", c->name.c_str(), user->nick.c_str(), u->nick.c_str());
FOREACH_MOD(OnUserInvite, (user,u,c,timeout));
} }
else if (IS_LOCAL(user)) else if (IS_LOCAL(user))
{ {