diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-03-22 12:03:43 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-03-22 12:03:43 +0000 |
commit | 68730d4c9701b34c962302e6410908865fb2ba28 (patch) | |
tree | dfa6b0b1d79bfd894ab75d0415e054b54ff2d850 /src/commands/cmd_invite.cpp | |
parent | 9ee525bec55521e9d911df40c2d8ca8b0212ee22 (diff) |
Wheeee for HUGE commits. Convert all numerics to WriteNumeric so that OnNumeric can capture them.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9175 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/commands/cmd_invite.cpp')
-rw-r--r-- | src/commands/cmd_invite.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/commands/cmd_invite.cpp b/src/commands/cmd_invite.cpp index 49296ca42..553915ac9 100644 --- a/src/commands/cmd_invite.cpp +++ b/src/commands/cmd_invite.cpp @@ -39,11 +39,11 @@ CmdResult CommandInvite::Handle (const char* const* parameters, int pcnt, User * { if (!c) { - user->WriteServ("401 %s %s :No such nick/channel",user->nick, parameters[1]); + user->WriteNumeric(401, "%s %s :No such nick/channel",user->nick, parameters[1]); } else { - user->WriteServ("401 %s %s :No such nick/channel",user->nick, parameters[0]); + user->WriteNumeric(401, "%s %s :No such nick/channel",user->nick, parameters[0]); } return CMD_FAILURE; @@ -53,20 +53,20 @@ CmdResult CommandInvite::Handle (const char* const* parameters, int pcnt, User * { if (c->GetStatus(user) < STATUS_HOP) { - user->WriteServ("482 %s %s :You must be a channel %soperator", user->nick, c->name, c->GetStatus(u) == STATUS_HOP ? "" : "half-"); + user->WriteNumeric(482, "%s %s :You must be a channel %soperator", user->nick, c->name, c->GetStatus(u) == STATUS_HOP ? "" : "half-"); return CMD_FAILURE; } } if (c->HasUser(u)) { - user->WriteServ("443 %s %s %s :is already on channel",user->nick,u->nick,c->name); + user->WriteNumeric(443, "%s %s %s :is already on channel",user->nick,u->nick,c->name); return CMD_FAILURE; } if ((IS_LOCAL(user)) && (!c->HasUser(user))) { - user->WriteServ("442 %s %s :You're not on that channel!",user->nick, c->name); + user->WriteNumeric(442, "%s %s :You're not on that channel!",user->nick, c->name); return CMD_FAILURE; } @@ -79,7 +79,7 @@ CmdResult CommandInvite::Handle (const char* const* parameters, int pcnt, User * u->InviteTo(c->name, timeout); u->WriteFrom(user,"INVITE %s :%s",u->nick,c->name); - user->WriteServ("341 %s %s %s",user->nick,u->nick,c->name); + user->WriteNumeric(341, "%s %s %s",user->nick,u->nick,c->name); switch (ServerInstance->Config->AnnounceInvites) { case ServerConfig::INVITE_ANNOUNCE_ALL: @@ -107,9 +107,9 @@ CmdResult CommandInvite::Handle (const char* const* parameters, int pcnt, User * InvitedList* il = user->GetInviteList(); for (InvitedList::iterator i = il->begin(); i != il->end(); i++) { - user->WriteServ("346 %s :%s",user->nick,i->first.c_str()); + user->WriteNumeric(346, "%s :%s",user->nick,i->first.c_str()); } - user->WriteServ("347 %s :End of INVITE list",user->nick); + user->WriteNumeric(347, "%s :End of INVITE list",user->nick); } return CMD_SUCCESS; } |