]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_ojoin.cpp
Allow Channel::WriteNotice send to other servers and status ranks.
[user/henk/code/inspircd.git] / src / modules / m_ojoin.cpp
index 2752a6ea8227614d68113fe60700b9361d979727..e3366056d5cca5145e21df4469dc6827df738548 100644 (file)
@@ -38,7 +38,7 @@ class CommandOjoin : public SplitCommand
                active = false;
        }
 
-       CmdResult HandleLocal(const std::vector<std::string>& parameters, LocalUser* user) CXX11_OVERRIDE
+       CmdResult HandleLocal(LocalUser* user, const Params& parameters) CXX11_OVERRIDE
        {
                // Make sure the channel name is allowable.
                if (!ServerInstance->IsChannel(parameters[0]))
@@ -57,11 +57,7 @@ class CommandOjoin : public SplitCommand
                        ServerInstance->SNO->WriteGlobalSno('a', user->nick+" used OJOIN to join "+channel->name);
 
                        if (notice)
-                       {
-                               const std::string msg = user->nick + " joined on official network business.";
-                               channel->WriteNotice(msg);
-                               ServerInstance->PI->SendChannelNotice(channel, 0, msg);
-                       }
+                               channel->WriteNotice(user->nick + " joined on official network business.");
                }
                else
                {
@@ -157,7 +153,7 @@ class ModuleOjoin : public Module
 
        Version GetVersion() CXX11_OVERRIDE
        {
-               return Version("Network Business Join", VF_VENDOR);
+               return Version("Provides the OJOIN command, allows an oper to join a channel and be immune to kicks", VF_VENDOR);
        }
 };