Software /
code /
prosody
Changeset
9013:a54bcc76cd22
MUC: Remove room state on successful restoration from disk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 11 Jul 2018 03:27:18 +0200 |
parents | 9012:295faf1522f9 |
children | 9014:326fedc1d3c6 |
files | plugins/muc/mod_muc.lua |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/muc/mod_muc.lua Wed Jul 11 03:27:02 2018 +0200 +++ b/plugins/muc/mod_muc.lua Wed Jul 11 03:27:18 2018 +0200 @@ -188,7 +188,12 @@ module:log("debug", "Could not restore state of room %s: %s", jid, s_err); end local room = muclib.restore_room(data, state); - return track_room(room); + if track_room(room) then + room_state:set(node, nil); + return room; + else + return false; + end elseif err then module:log("error", "Error restoring room %s from storage: %s", jid, err); local room = muclib.new_room(jid, { locked = math.huge });