Software /
code /
prosody
Comparison
plugins/mod_private.lua @ 438:193f9dd64f17
Bumper commit for the new modulemanager API \o/ Updates all the modules, though some more changes may be in store.
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Thu, 27 Nov 2008 03:12:12 +0000 |
parent | 421:63be85693710 |
child | 519:cccd610a0ef9 |
comparison
equal
deleted
inserted
replaced
437:c1a720db2157 | 438:193f9dd64f17 |
---|---|
4 local jid_split = require "util.jid".split; | 4 local jid_split = require "util.jid".split; |
5 local datamanager = require "util.datamanager" | 5 local datamanager = require "util.datamanager" |
6 | 6 |
7 require "core.discomanager".set("private", "jabber:iq:private"); | 7 require "core.discomanager".set("private", "jabber:iq:private"); |
8 | 8 |
9 add_iq_handler("c2s", "jabber:iq:private", | 9 module:add_iq_handler("c2s", "jabber:iq:private", |
10 function (session, stanza) | 10 function (session, stanza) |
11 local type = stanza.attr.type; | 11 local type = stanza.attr.type; |
12 local query = stanza.tags[1]; | 12 local query = stanza.tags[1]; |
13 if (type == "get" or type == "set") and query.name == "query" then | 13 if (type == "get" or type == "set") and query.name == "query" then |
14 local node, host = jid_split(stanza.attr.to); | 14 local node, host = jid_split(stanza.attr.to); |