]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_spanningtree/ping.cpp
Add support for blocking tag messages with the deaf mode.
[user/henk/code/inspircd.git] / src / modules / m_spanningtree / ping.cpp
index 537efe96466488af37948961335f9ae38d6c42ca..df4d920735e7286ba67f73b5db783ba0bd2b0c5a 100644 (file)
@@ -1,6 +1,11 @@
 /*
  * InspIRCd -- Internet Relay Chat Daemon
  *
+ *   Copyright (C) 2018-2019 Sadie Powell <sadie@witchery.services>
+ *   Copyright (C) 2013 Attila Molnar <attilamolnar@hush.com>
+ *   Copyright (C) 2012 Robby <robby@chatbelgie.be>
+ *   Copyright (C) 2010 Craig Edwards <brain@inspircd.org>
+ *   Copyright (C) 2009 Daniel De Graaf <danieldg@inspircd.org>
  *   Copyright (C) 2008 Robin Burchell <robin+git@viroteck.net>
  *
  * This file is part of InspIRCd.  InspIRCd is free software: you can
 #include "commands.h"
 #include "utils.h"
 
-CmdResult CommandPing::Handle(User* user, std::vector<std::string>& params)
+CmdResult CommandPing::Handle(User* user, Params& params)
 {
        if (params[0] == ServerInstance->Config->GetSID())
        {
                // PING for us, reply with a PONG
-               parameterlist reply;
-               reply.push_back(user->uuid);
+               CmdBuilder reply("PONG");
+               reply.push(user->uuid);
                if (params.size() >= 2)
                        // If there is a second parameter, append it
-                       reply.push_back(params[1]);
+                       reply.push(params[1]);
 
-               Utils->DoOneToOne(params[0], "PONG", reply, user->server);
+               reply.Unicast(user);
        }
        return CMD_SUCCESS;
 }
-
-