Mercurial > prosody-modules
changeset 1277:999891a9ae5d
mod_mam_muc: Remove archives when a room is destroyed
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 18 Jan 2014 21:07:12 +0100 |
parents | 01dfaf2f2782 |
children | 40f077b18dfe |
files | mod_mam_muc/mod_mam_muc.lua |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mod_mam_muc/mod_mam_muc.lua Sat Jan 18 21:06:15 2014 +0100 +++ b/mod_mam_muc/mod_mam_muc.lua Sat Jan 18 21:07:12 2014 +0100 @@ -184,6 +184,10 @@ module:hook("message/bare", message_handler, 2); +module:hook("muc-room-destroyed", function(event) + archive:delete(jid_split(event.room.jid)); +end); + -- TODO should we perhaps log presence as well? -- And role/affiliation changes?