]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_sakick.cpp
Add Base64 encode/decode functions to the core
[user/henk/code/inspircd.git] / src / modules / m_sakick.cpp
index d8eda095641447158c1b37d3310273b270dfce72..454214b1c7dbb2fcc0e23f43a913762dbedd0152 100644 (file)
@@ -2,7 +2,7 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
+ *  InspIRCd: (C) 2002-2010 InspIRCd Development Team
  * See: http://wiki.inspircd.org/Credits
  *
  * This program is free but copyrighted software; see
@@ -31,7 +31,6 @@ class CommandSakick : public Command
                User* dest = ServerInstance->FindNick(parameters[1]);
                Channel* channel = ServerInstance->FindChan(parameters[0]);
                const char* reason = "";
-               const char* servername = NULL;
 
                if (dest && channel)
                {
@@ -56,8 +55,7 @@ class CommandSakick : public Command
                         */
                        if (IS_LOCAL(dest))
                        {
-                               if (!channel->ServerKickUser(dest, reason, servername))
-                                       delete channel;
+                               channel->KickUser(ServerInstance->FakeClient, dest, reason);
 
                                Channel *n = ServerInstance->FindChan(parameters[1]);
                                if (n && n->HasUser(dest))
@@ -97,8 +95,8 @@ class ModuleSakick : public Module
 {
        CommandSakick cmd;
  public:
-       ModuleSakick(InspIRCd* Me)
-               : Module(Me), cmd(this)
+       ModuleSakick()
+               : cmd(this)
        {
                ServerInstance->AddCommand(&cmd);
        }
@@ -109,7 +107,7 @@ class ModuleSakick : public Module
 
        virtual Version GetVersion()
        {
-               return Version("$Id$", VF_OPTCOMMON|VF_VENDOR, API_VERSION);
+               return Version("Provides a SAKICK command", VF_OPTCOMMON|VF_VENDOR);
        }
 
 };