# HG changeset patch # User Matthew Wild # Date 1248887497 -3600 # Node ID 1ca7a247d04f43e779c2b5d3703231bb34be3e99 # Parent ba2a92230b77f978893ce57970e0adca49d7c1ec# Parent a63ff2fbba8d0a29503e7552a29fc7c831faa23c Merge with 0.5 diff -r ba2a92230b77 -r 1ca7a247d04f plugins/mod_pep.lua --- a/plugins/mod_pep.lua Tue Jul 28 19:17:09 2009 +0100 +++ b/plugins/mod_pep.lua Wed Jul 29 18:11:37 2009 +0100 @@ -30,6 +30,7 @@ local function publish(session, node, item) local disable = #item.tags ~= 1 or #item.tags[1].tags == 0; + if #item.tags == 0 then item.name = "retract"; end local bare = session.username..'@'..session.host; local stanza = st.message({from=bare, type='headline'}) :tag('event', {xmlns='http://jabber.org/protocol/pubsub#event'}) @@ -128,7 +129,7 @@ local payload = stanza.tags[1]; if payload.name == 'pubsub' then -- payload = payload.tags[1]; - if payload and payload.name == 'publish' and payload.attr.node then -- + if payload and (payload.name == 'publish' or payload.name == 'retract') and payload.attr.node then -- local node = payload.attr.node; payload = payload.tags[1]; if payload then -- diff -r ba2a92230b77 -r 1ca7a247d04f prosody --- a/prosody Tue Jul 28 19:17:09 2009 +0100 +++ b/prosody Wed Jul 29 18:11:37 2009 +0100 @@ -9,9 +9,9 @@ -- Will be modified by configure script if run -- -CFG_SOURCEDIR=nil; +CFG_SOURCEDIR=os.getenv("PROSODY_SRCDIR"); CFG_CONFIGDIR=os.getenv("PROSODY_CFGDIR"); -CFG_PLUGINDIR=nil; +CFG_PLUGINDIR=os.getenv("PROSODY_PLUGINDIR"); CFG_DATADIR=os.getenv("PROSODY_DATADIR"); -- -- -- -- -- -- -- ---- -- -- -- -- -- -- -- -- diff -r ba2a92230b77 -r 1ca7a247d04f util/muc.lua --- a/util/muc.lua Tue Jul 28 19:17:09 2009 +0100 +++ b/util/muc.lua Wed Jul 29 18:11:37 2009 +0100 @@ -209,7 +209,7 @@ else -- change nick if self._participants[to] then log("debug", "%s couldn't change nick", current_nick); - origin.send(st.error_reply(stanza, "cancel", "conflict")); + origin.send(st.error_reply(stanza, "cancel", "conflict"):tag("x", {xmlns = "http://jabber.org/protocol/muc"})); else local data = self._participants[current_nick]; local to_nick = select(3, jid_split(to)); @@ -240,7 +240,7 @@ end if not new_nick then log("debug", "%s couldn't join due to nick conflict: %s", from, to); - origin.send(st.error_reply(stanza, "cancel", "conflict")); + origin.send(st.error_reply(stanza, "cancel", "conflict"):tag("x", {xmlns = "http://jabber.org/protocol/muc"})); else log("debug", "%s joining as %s", from, to); local data;