From feeeced47094ed52541d1bc74440f1b223e6dadc Mon Sep 17 00:00:00 2001 From: brain Date: Thu, 8 Mar 2007 11:26:31 +0000 Subject: option to allow announce of invites to channel (similar to unreal) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6635 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/cmd_invite.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/cmd_invite.cpp') diff --git a/src/cmd_invite.cpp b/src/cmd_invite.cpp index 88b64f03d..2910aca3f 100644 --- a/src/cmd_invite.cpp +++ b/src/cmd_invite.cpp @@ -74,10 +74,11 @@ CmdResult cmd_invite::Handle (const char** parameters, int pcnt, userrec *user) return CMD_FAILURE; } - irc::string xname(c->name); - u->InviteTo(xname); + u->InviteTo(c->name); u->WriteFrom(user,"INVITE %s :%s",u->nick,c->name); user->WriteServ("341 %s %s %s",user->nick,u->nick,c->name); + if (ServerInstance->Config->AnnounceInvites) + c->WriteChannelWithServ(ServerInstance->Config->ServerName, "%s invited %s into the channel", user->nick, u->nick) FOREACH_MOD(I_OnUserInvite,OnUserInvite(user,u,c)); } else -- cgit v1.2.3