]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_tline.cpp
Merge pull request #514 from SaberUK/master+virtual-cleanup
[user/henk/code/inspircd.git] / src / modules / m_tline.cpp
index aca95c0a1439168d91c1160e7115a936fd2a81d8..6e0ebca3d0897f214dd872140f514d6bc98e315f 100644 (file)
@@ -49,7 +49,7 @@ class CommandTline : public Command
                        }
                        else
                        {
-                               std::string host = std::string(u->second->ident) + "@" + u->second->GetIPString();
+                               std::string host = u->second->ident + "@" + u->second->GetIPString();
                                if (InspIRCd::MatchCIDR(host, parameters[0]))
                                {
                                        n_matched++;
@@ -73,19 +73,17 @@ class ModuleTLine : public Module
        ModuleTLine()
                : cmd(this)
        {
-               ServerInstance->AddCommand(&cmd);
        }
 
-
-       virtual ~ModuleTLine()
+       void init() CXX11_OVERRIDE
        {
+               ServerInstance->Modules->AddService(cmd);
        }
 
-       virtual Version GetVersion()
+       Version GetVersion() CXX11_OVERRIDE
        {
                return Version("Provides /tline command used to test who a mask matches", VF_VENDOR);
        }
 };
 
 MODULE_INIT(ModuleTLine)
-