diff options
author | Peter Powell <petpow@saberuk.com> | 2018-04-22 13:31:00 +0100 |
---|---|---|
committer | Peter Powell <petpow@saberuk.com> | 2018-04-22 13:31:00 +0100 |
commit | ba31d8080f75a0147d0b380f2c51251e024f0deb (patch) | |
tree | bbe926ced0451e1a75ca62e3854543c2e05f73c3 | |
parent | 35b70631f0532a5828b04a8e0c02092a285f331a (diff) |
Replace ERR_{NOCTCPALLOWED,WORDFILTERED} with ERR_CANNOTSENDTOCHAN.
There is no reason for these responses to have their own numerics
when other modules do not. The only thing this does is make life
harder for client developers.
-rw-r--r-- | include/numerics.h | 3 | ||||
-rw-r--r-- | src/modules/m_censor.cpp | 2 | ||||
-rw-r--r-- | src/modules/m_noctcp.cpp | 2 |
3 files changed, 2 insertions, 5 deletions
diff --git a/include/numerics.h b/include/numerics.h index 2a3f090e7..b4ab0451b 100644 --- a/include/numerics.h +++ b/include/numerics.h @@ -173,8 +173,6 @@ enum ERR_ALLMUSTSSL = 490, // unrealircd ERR_NOOPERHOST = 491, - ERR_NOCTCPALLOWED = 492, // XXX: bzzzz. 1459 defines this as ERR_NOSERVICEHOST, research it more and perhaps change this! (ERR_CANNOTSENDTOCHAN?) - // wtf, we also use this for m_noinvite. UGLY! ERR_DELAYREJOIN = 495, // insp-specific, XXX: we should use 'resource temporarily unavailable' from ircnet/ratbox or whatever ERR_UNKNOWNSNOMASK = 501, // insp-specific ERR_USERSDONTMATCH = 502, @@ -190,7 +188,6 @@ enum RPL_OTHERUMODEIS = 803, // insp-specific RPL_OTHERSNOMASKIS = 804, // insp-specific - ERR_WORDFILTERED = 936, // insp-specific, would be nice if we could get rid of this.. ERR_CANTUNLOADMODULE = 972, // insp-specific RPL_UNLOADEDMODULE = 973, // insp-specific ERR_CANTLOADMODULE = 974, // insp-specific diff --git a/src/modules/m_censor.cpp b/src/modules/m_censor.cpp index cb2bec85a..9044c90b1 100644 --- a/src/modules/m_censor.cpp +++ b/src/modules/m_censor.cpp @@ -71,7 +71,7 @@ class ModuleCensor : public Module if (index->second.empty()) { const std::string targname = target.type == MessageTarget::TYPE_CHANNEL ? target.Get<Channel>()->name : target.Get<User>()->nick; - user->WriteNumeric(ERR_WORDFILTERED, targname, index->first.c_str(), "Your message contained a censored word, and was blocked"); + user->WriteNumeric(ERR_CANNOTSENDTOCHAN, targname, index->first.c_str(), "Your message contained a censored word, and was blocked"); return MOD_RES_DENY; } diff --git a/src/modules/m_noctcp.cpp b/src/modules/m_noctcp.cpp index 26077759a..dbfe55eac 100644 --- a/src/modules/m_noctcp.cpp +++ b/src/modules/m_noctcp.cpp @@ -53,7 +53,7 @@ class ModuleNoCTCP : public Module if (!c->GetExtBanStatus(user, 'C').check(!c->IsModeSet(nc))) { - user->WriteNumeric(ERR_NOCTCPALLOWED, c->name, "Can't send CTCP to channel (+C set)"); + user->WriteNumeric(ERR_CANNOTSENDTOCHAN, c->name, "Can't send CTCP to channel (+C set)"); return MOD_RES_DENY; } } |