]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_setident.cpp
Include explicit routing information in Command, will replace CMD_LOCALONLY return...
[user/henk/code/inspircd.git] / src / modules / m_setident.cpp
index 867404ddb1da4e07ec77e58fe4afe6d2b159cf99..7823b041b86db4c898be6e40c80c3408b7222da1 100644 (file)
@@ -48,7 +48,7 @@ class CommandSetident : public Command
                }
 
                user->ChangeIdent(parameters[0].c_str());
-               ServerInstance->SNO->WriteToSnoMask('A', "%s used SETIDENT to change their ident to '%s'", user->nick.c_str(), user->ident.c_str());
+               ServerInstance->SNO->WriteGlobalSno('a', "%s used SETIDENT to change their ident to '%s'", user->nick.c_str(), user->ident.c_str());
 
                return CMD_SUCCESS;
        }
@@ -57,15 +57,12 @@ class CommandSetident : public Command
 
 class ModuleSetIdent : public Module
 {
-       CommandSetident*        mycommand;
+       CommandSetident cmd;
 
  public:
-       ModuleSetIdent(InspIRCd* Me) : Module(Me)
+       ModuleSetIdent(InspIRCd* Me) : Module(Me), cmd(Me)
        {
-
-               mycommand = new CommandSetident(ServerInstance);
-               ServerInstance->AddCommand(mycommand);
-
+               ServerInstance->AddCommand(&cmd);
        }
 
        virtual ~ModuleSetIdent()