Merge
[prosody.git] / plugins / mod_ping.lua
index c13282fffd30e5cc913767ac5469b3c54d124e7c..2cefff6162ebb41666aeb9bddcfc273baea5593e 100644 (file)
@@ -1,9 +1,18 @@
+-- Prosody IM v0.4
+-- Copyright (C) 2008-2009 Matthew Wild
+-- Copyright (C) 2008-2009 Waqas Hussain
+-- 
+-- This project is MIT/X11 licensed. Please see the
+-- COPYING file in the source package for more information.
+--
+
+
 \r
 local st = require "util.stanza";\r
 \r
-require "core.discomanager".set("ping", "urn:xmpp:ping");\r
+module:add_feature("urn:xmpp:ping");\r
 \r
-add_iq_handler({"c2s", "s2sin"}, "urn:xmpp:ping",\r
+module:add_iq_handler({"c2s", "s2sin"}, "urn:xmpp:ping",\r
        function(session, stanza)\r
                if stanza.attr.type == "get" then\r
                        session.send(st.reply(stanza));\r