# HG changeset patch # User Kim Alvefur # Date 1390075632 -3600 # Node ID 999891a9ae5ddc440ea38832a13173da228578f1 # Parent 01dfaf2f2782502660e69f1bb8d4d0062f9387a1 mod_mam_muc: Remove archives when a room is destroyed diff -r 01dfaf2f2782 -r 999891a9ae5d mod_mam_muc/mod_mam_muc.lua --- 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?