From: Kim Alvefur Date: Mon, 18 Apr 2016 14:51:09 +0000 (+0200) Subject: MUC: Assign occupants unavailable presence on room destruction, fixes destruction... X-Git-Url: https://git.enpas.org/?a=commitdiff_plain;h=08b19bb731babd4d3a8697f2e6bbf8b61aa1c3cc;p=prosody.git MUC: Assign occupants unavailable presence on room destruction, fixes destruction notification --- diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua index 14cbd63c..434127b4 100644 --- a/plugins/muc/muc.lib.lua +++ b/plugins/muc/muc.lib.lua @@ -727,6 +727,7 @@ function room_mt:clear(x) occupants_updated[occupant] = true; end for occupant in pairs(occupants_updated) do + occupant:set_session(occupant.jid, st.presence({type="unavailable"}), true); self:publicise_occupant_status(occupant, x); module:fire_event("muc-occupant-left", { room = self; nick = occupant.nick; occupant = occupant;}); end