diff options
author | Sam Whited <sam@samwhited.com> | 2016-09-02 16:02:17 -0500 |
---|---|---|
committer | Sam Whited <sam@samwhited.com> | 2016-09-02 16:02:17 -0500 |
commit | 598b3b441e7f40612f96fcf59e17de2b594d6f3b (patch) | |
tree | d86563a5aa6bcb91edab1a6b07021083d336cb17 /plugins/muc/mod_muc.lua | |
parent | 088d94cf1e4c14e24a36d609ae255d51c23f3614 (diff) | |
download | prosody-598b3b441e7f40612f96fcf59e17de2b594d6f3b.tar.gz prosody-598b3b441e7f40612f96fcf59e17de2b594d6f3b.zip |
Logging error if MUC room cache is full
Diffstat (limited to 'plugins/muc/mod_muc.lua')
-rw-r--r-- | plugins/muc/mod_muc.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/muc/mod_muc.lua b/plugins/muc/mod_muc.lua index 41b84a86..d8553d5e 100644 --- a/plugins/muc/mod_muc.lua +++ b/plugins/muc/mod_muc.lua @@ -114,8 +114,8 @@ local function room_save(room, forced, savestate) end end -local rooms = cache.new(module:get_option_number("muc_room_cache_size", 100), function (_, room) - module:log("debug", "%s evicted", room); +local rooms = cache.new(module:get_option_number("muc_room_cache_size", 100), function (jid, room) + module:log("debug", "%s evicted", jid); room_save(room, nil, true); -- Force to disk end); @@ -151,7 +151,7 @@ function forget_room(room) end function delete_room(room) - module:log("debug", "Deleting %s", room); + module:log("debug", "Deleting %s", room.jid); room_configs:set(jid_split(room.jid), nil); persistent_rooms:set(nil, room.jid, nil); room_items_cache[room.jid] = nil; |