Changeset

3182:a19dbb6446a0

mod_presence: Don't stop pre-event for outgoing probes.
author Waqas Hussain <waqas20@gmail.com>
date Fri, 04 Jun 2010 18:30:18 +0500
parents 3181:1f73b3a960cf
children 3183:28a5c0bda928
files plugins/mod_presence.lua
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_presence.lua	Fri Jun 04 18:24:09 2010 +0500
+++ b/plugins/mod_presence.lua	Fri Jun 04 18:30:18 2010 +0500
@@ -187,7 +187,10 @@
 	local st_from, st_to = stanza.attr.from, stanza.attr.to;
 	stanza.attr.from, stanza.attr.to = from_bare, to_bare;
 	log("debug", "outbound presence "..stanza.attr.type.." from "..from_bare.." for "..to_bare);
-	if stanza.attr.type == "subscribe" then
+	if stanza.attr.type == "probe" then
+		stanza.attr.from, stanza.attr.to = st_from, st_to;
+		return;
+	elseif stanza.attr.type == "subscribe" then
 		-- 1. route stanza
 		-- 2. roster push (subscription = none, ask = subscribe)
 		if rostermanager.set_contact_pending_out(node, host, to_bare) then