From 0f8bbd85dd81b0c976e4ff4045c6f77dcc1b7530 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Wed, 4 May 2016 12:14:15 +0200 Subject: [PATCH] MUC: Move status text out of element (thanks Tobias) --- plugins/muc/muc.lib.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua index 238cd3e1..eb992aa3 100644 --- a/plugins/muc/muc.lib.lua +++ b/plugins/muc/muc.lib.lua @@ -531,10 +531,10 @@ function room_mt:handle_normal_presence(origin, stanza) if not is_first_dest_session then -- User is swapping into another pre-existing session log("debug", "session %s is swapping into multisession %s, showing it leave.", real_jid, dest_occupant.nick); -- Show the other session leaving - local x = st.stanza("x", {xmlns = "http://jabber.org/protocol/muc#user";}) - :tag("status"):text("you are joining pre-existing session " .. dest_nick):up(); + local x = st.stanza("x", {xmlns = "http://jabber.org/protocol/muc#user";}); add_item(x, self:get_affiliation(bare_jid), "none"); local pr = st.presence{from = dest_occupant.nick, to = real_jid, type = "unavailable"} + :tag("status"):text("you are joining pre-existing session " .. dest_nick):up() :add_child(x); self:route_stanza(pr); end -- 2.30.2