X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_operchans.cpp;h=8484d7dcc25cc658362d4d63768b5db0330a1b4e;hb=43e31bba5429849fdebeddc65f7e6f267211181f;hp=3c6b4cd59c96f72de160d9a208da70b6ef9bc009;hpb=0b63ccd0b5cb26883d6becb196fb98e4f95d0397;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_operchans.cpp b/src/modules/m_operchans.cpp index 3c6b4cd59..8484d7dcc 100644 --- a/src/modules/m_operchans.cpp +++ b/src/modules/m_operchans.cpp @@ -22,6 +22,12 @@ #include "inspircd.h" +enum +{ + // From UnrealIRCd. + ERR_CANTJOINOPERSONLY = 520 +}; + class OperChans : public SimpleChannelModeHandler { public: @@ -44,8 +50,7 @@ class ModuleOperChans : public Module { if (chan && chan->IsModeSet(oc) && !user->IsOper()) { - user->WriteNumeric(ERR_CANTJOINOPERSONLY, "%s :Only IRC operators may join %s (+O is set)", - chan->name.c_str(), chan->name.c_str()); + user->WriteNumeric(ERR_CANTJOINOPERSONLY, chan->name, InspIRCd::Format("Only server operators may join %s (+O is set)", chan->name.c_str())); return MOD_RES_DENY; } return MOD_RES_PASSTHRU; @@ -68,7 +73,7 @@ class ModuleOperChans : public Module Version GetVersion() CXX11_OVERRIDE { - return Version("Provides support for oper-only chans via the +O channel mode and 'O' extban", VF_VENDOR); + return Version("Provides support for oper-only channels via channel mode +O and extban 'O'", VF_VENDOR); } };