aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWaqas Hussain <waqas20@gmail.com>2009-05-08 04:41:18 +0500
committerWaqas Hussain <waqas20@gmail.com>2009-05-08 04:41:18 +0500
commit89fb8fa9f7e7922bed6aabd3de771cef5a00f1b5 (patch)
tree9b87c5150b4ed8e991517381debd741fe0f96d1c
parent3f6a1b347ff895ab9ec9c0c716005b8460300725 (diff)
downloadprosody-89fb8fa9f7e7922bed6aabd3de771cef5a00f1b5.tar.gz
prosody-89fb8fa9f7e7922bed6aabd3de771cef5a00f1b5.zip
mod_muc: commented connection replace detection code because google keeps resendng directed presence
-rw-r--r--plugins/mod_muc.lua12
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/mod_muc.lua b/plugins/mod_muc.lua
index 35900f60..38f21b4a 100644
--- a/plugins/mod_muc.lua
+++ b/plugins/mod_muc.lua
@@ -260,7 +260,7 @@ function handle_to_occupant(origin, stanza) -- PM, vCards, etc
end
elseif not type then -- available
if current_nick then
- if #pr == #stanza or current_nick ~= to then
+ --if #pr == #stanza or current_nick ~= to then -- commented because google keeps resending directed presence
if current_nick == to then -- simple presence
log("debug", "%s broadcasted presence", current_nick);
rooms:get(room, current_nick).sessions[from] = pr;
@@ -287,11 +287,11 @@ function handle_to_occupant(origin, stanza) -- PM, vCards, etc
end
end
end
- else -- possible rejoin
- log("debug", "%s had connection replaced", current_nick);
- handle_to_occupant(origin, st.presence({type='unavailable', from=from, to=to}):tag('status'):text('Replaced by new connection'):up()); -- send unavailable
- handle_to_occupant(origin, stanza); -- resend available
- end
+ --else -- possible rejoin
+ -- log("debug", "%s had connection replaced", current_nick);
+ -- handle_to_occupant(origin, st.presence({type='unavailable', from=from, to=to}):tag('status'):text('Replaced by new connection'):up()); -- send unavailable
+ -- handle_to_occupant(origin, stanza); -- resend available
+ --end
else -- enter room
local new_nick = to;
if rooms:get(room, to) then