From 89fb8fa9f7e7922bed6aabd3de771cef5a00f1b5 Mon Sep 17 00:00:00 2001 From: Waqas Hussain Date: Fri, 8 May 2009 04:41:18 +0500 Subject: mod_muc: commented connection replace detection code because google keeps resendng directed presence --- plugins/mod_muc.lua | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'plugins') 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 -- cgit v1.2.3