X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fmodules%2Fm_sakick.cpp;h=7dfcd8904db3b7e8531059e270274a6eac547cb5;hb=4e3d7a6e30eadf714483994681b8b2534229f4a8;hp=3926a18e66c62c44fce5716a1764bc8c8cc110c1;hpb=c8b41aa5d256d99eee67ec94492a94dc30e0ea35;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_sakick.cpp b/src/modules/m_sakick.cpp index 3926a18e6..7dfcd8904 100644 --- a/src/modules/m_sakick.cpp +++ b/src/modules/m_sakick.cpp @@ -39,7 +39,7 @@ class CommandSakick : public Command Channel* channel = ServerInstance->FindChan(parameters[0]); const char* reason = ""; - if (dest && channel) + if ((dest) && (dest->registered == REG_ALL) && (channel)) { if (parameters.size() > 2) { @@ -105,7 +105,11 @@ class ModuleSakick : public Module ModuleSakick() : cmd(this) { - ServerInstance->AddCommand(&cmd); + } + + void init() + { + ServerInstance->Modules->AddService(cmd); } virtual ~ModuleSakick()