Software /
code /
prosody
Diff
plugins/muc/mod_muc.lua @ 5997:2d652afa57e4
MUC: Fire muc-room-destroyed event when the last participant leaves a non-persistent room
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 18 Jan 2014 20:14:05 +0100 |
parent | 5943:355f8b59bf1b |
child | 6000:0f6399c86c10 |
child | 6741:bea3862b6bde |
line wrap: on
line diff
--- a/plugins/muc/mod_muc.lua Sat Jan 18 10:37:12 2014 -0500 +++ b/plugins/muc/mod_muc.lua Sat Jan 18 20:14:05 2014 +0100 @@ -163,6 +163,7 @@ if room then room:handle_stanza(origin, stanza); if not next(room._occupants) and not persistent_rooms[room.jid] then -- empty, non-persistent room + module:fire_event("muc-room-destroyed", { room = room }); rooms[bare] = nil; -- discard room end else