summaryrefslogtreecommitdiff
path: root/src/commands.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-05-22 14:42:06 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-05-22 14:42:06 +0000
commitd8c41ff4751db37b6b8a403844cd3b9e293bc85a (patch)
tree0f88be356d37a9cddc20a667c83125f9fa3b4b7c /src/commands.cpp
parent085f7e07d460a2fef17a507f0cc0f9ccd4561724 (diff)
Added OnUserPreJoin trigger
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@818 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/commands.cpp')
-rw-r--r--src/commands.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/commands.cpp b/src/commands.cpp
index 94603d8e9..ffa09156b 100644
--- a/src/commands.cpp
+++ b/src/commands.cpp
@@ -431,6 +431,13 @@ void handle_invite(char **parameters, int pcnt, userrec *user)
WriteServ(user->fd,"442 %s %s :You're not on that channel!",user->nick, c->name);
return;
}
+
+ int MOD_RESULT = 0;
+ FOREACH_RESULT(OnUserPreInvite(user,u,c));
+ if (MOD_RESULT == 1) {
+ return NULL;
+ }
+
u->InviteTo(c->name);
WriteFrom(u->fd,user,"INVITE %s :%s",u->nick,c->name);
WriteServ(user->fd,"341 %s %s %s",user->nick,u->nick,c->name);