public:
ModuleKnock(InspIRCd* Me) : Module(Me)
{
-
kn = new Knock(ServerInstance);
+
if (!ServerInstance->AddMode(kn, 'K'))
throw ModuleException("Could not add new modes!");
+
mycommand = new cmd_knock(ServerInstance);
ServerInstance->AddCommand(mycommand);
}
virtual ~ModuleKnock()
{
ServerInstance->Modes->DelMode(kn);
- DELETE(kn);
+ delete kn;
}
virtual Version GetVersion()