]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/snomasks.cpp
Improve X-line text consistency.
[user/henk/code/inspircd.git] / src / snomasks.cpp
index fd6a2709a13c4d180e6432138ec2dabb80773c77..e39fb84fb748f05a131ce75174280c24d86c04f4 100644 (file)
@@ -69,9 +69,8 @@ SnomaskManager::SnomaskManager()
        EnableSnomask('q',"QUIT");                      /* Local quit notices */
        EnableSnomask('k',"KILL");                      /* Kill notices */
        EnableSnomask('o',"OPER");                      /* Oper up/down notices */
-       EnableSnomask('a',"ANNOUNCEMENT");      /* formerly WriteOpers() - generic notices to all opers */
-       EnableSnomask('d',"DEBUG");                     /* Debug notices */
-       EnableSnomask('x',"XLINE");                     /* Xline notice (g/z/q/k/e) */
+       EnableSnomask('a',"ANNOUNCEMENT");              /* formerly WriteOpers() - generic notices to all opers */
+       EnableSnomask('x',"XLINE");                     /* X-line notices (G/Z/Q/K/E/R/SHUN/CBan) */
        EnableSnomask('t',"STATS");                     /* Local or remote stats request */
 }
 
@@ -124,12 +123,9 @@ void Snomask::Flush()
 
 void Snomask::Send(char letter, const std::string& desc, const std::string& msg)
 {
-       std::string log = desc;
-       log.append(": ").append(msg);
-       ServerInstance->Logs->Log("snomask", LOG_DEFAULT, log);
+       ServerInstance->Logs->Log(desc, LOG_DEFAULT, msg);
+       const std::string finalmsg = InspIRCd::Format("*** %s: %s", desc.c_str(), msg.c_str());
 
-       std::string finalmsg = "*** ";
-       finalmsg.append(log);
        /* Only opers can receive snotices, so we iterate the oper list */
        const UserManager::OperList& opers = ServerInstance->Users->all_opers;
        for (UserManager::OperList::const_iterator i = opers.begin(); i != opers.end(); ++i)