From f052efe12448d7ad991e90724f064346a12e3a1b Mon Sep 17 00:00:00 2001 From: w00t Date: Tue, 5 Aug 2008 14:59:06 +0000 Subject: Send ERR_BANNEDFROMCHAN on all extbans preventing join git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10094 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_channelban.cpp | 3 +-- src/modules/m_gecosban.cpp | 3 +-- src/modules/m_serverban.cpp | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/modules/m_channelban.cpp b/src/modules/m_channelban.cpp index 0da6cef2c..66851c5a2 100644 --- a/src/modules/m_channelban.cpp +++ b/src/modules/m_channelban.cpp @@ -47,8 +47,7 @@ class ModuleBadChannelExtban : public Module { if (c->IsExtBanned(i->first->name, 'j')) { - // XXX: send a numeric here - user->WriteServ("NOTICE "+std::string(user->nick)+" :*** Cannot join " + c->name + ", as you match a ban"); + user->WriteNumeric(ERR_BANNEDFROMCHAN, "%s %s :Cannot join channel (You're banned)", user->nick.c_str(), c->name.c_str()); return 1; } } diff --git a/src/modules/m_gecosban.cpp b/src/modules/m_gecosban.cpp index a59508e06..c7194aef5 100644 --- a/src/modules/m_gecosban.cpp +++ b/src/modules/m_gecosban.cpp @@ -44,8 +44,7 @@ class ModuleGecosBan : public Module if (c->IsExtBanned(user->fullname, 'r')) { - // XXX: send a numeric here - user->WriteServ("NOTICE "+std::string(user->nick)+" :*** Cannot join " + c->name + ", as you match a ban"); + user->WriteNumeric(ERR_BANNEDFROMCHAN, "%s %s :Cannot join channel (You're banned)", user->nick.c_str(), c->name.c_str()); return 1; } diff --git a/src/modules/m_serverban.cpp b/src/modules/m_serverban.cpp index e6fda051c..7d57466cd 100644 --- a/src/modules/m_serverban.cpp +++ b/src/modules/m_serverban.cpp @@ -44,8 +44,7 @@ class ModuleServerBan : public Module if (c->IsExtBanned(user->server, 's')) { - // XXX: send a numeric here - user->WriteServ("NOTICE "+std::string(user->nick)+" :*** Cannot join " + c->name + ", as you match a ban"); + user->WriteNumeric(ERR_BANNEDFROMCHAN, "%s %s :Cannot join channel (You're banned)", user->nick.c_str(), c->name.c_str()); return 1; } -- cgit v1.2.3