# HG changeset patch # User Jonas Schäfer # Date 1612301289 -3600 # Node ID ca821df93cb962bd567eb12b1fbbaef2faadda1d # Parent 2047dd56cc40dcd596b77d7304da97a5fc38f0e7 mod_groups_internal: correctly destroy MUC associated with group Turns out, delete does not do what I think it does. destroy does what I think it does. diff -r 2047dd56cc40 -r ca821df93cb9 mod_groups_internal/mod_groups_internal.lua --- a/mod_groups_internal/mod_groups_internal.lua Mon Feb 01 16:43:27 2021 +0100 +++ b/mod_groups_internal/mod_groups_internal.lua Tue Feb 02 22:28:09 2021 +0100 @@ -122,7 +122,7 @@ }); if not ok then if room then - muc_host:delete_room(room) + room:destroy() end return nil, "internal-server-error"; end @@ -182,7 +182,10 @@ if group_members_store:set(group_id, nil) then local group_info = get_info(group_id); if group_info and group_info.muc_jid then - muc_host.delete_room(muc_host.get_room_from_jid(group_info.muc_jid)); + local room = muc_host.get_room_from_jid(group_info.muc_jid) + if room then + room:destroy() + end end return group_info_store:set(group_id, nil); end