aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-09-22 16:03:50 +0200
committerKim Alvefur <zash@zash.se>2018-09-22 16:03:50 +0200
commit94b922ba3f60c0ab41302157ede9951f323a060c (patch)
tree0bb3d0e6c2b2f603b95fbf95b403fe7de51dab4b
parentfdbf28899fafaa2e2fcc9854e6b217bb8c78e92f (diff)
downloadprosody-94b922ba3f60c0ab41302157ede9951f323a060c.tar.gz
prosody-94b922ba3f60c0ab41302157ede9951f323a060c.zip
mod_storage_memory: Fix saving of remaining items during deletion
All data is compiled into functions that return new copies in order to prevent mutation of stored data. This has downsides. Also an ugly hack.
-rw-r--r--plugins/mod_storage_memory.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_storage_memory.lua b/plugins/mod_storage_memory.lua
index 8a95a587..49df48eb 100644
--- a/plugins/mod_storage_memory.lua
+++ b/plugins/mod_storage_memory.lua
@@ -128,7 +128,7 @@ function archive_store:delete(username, query)
i = old[i];
t = i.when;
if not(qstart >= t and qend <= t and (not qwith or i.with == qwith)) then
- self:append(username, i.key, i.value, t, i.with);
+ self:append(username, i.key, i.value(), t, i.with);
end
end
if #new == 0 then