aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2017-05-20 14:58:56 +0200
committerKim Alvefur <zash@zash.se>2017-05-20 14:58:56 +0200
commit06b5c50c4e4751e54ca01175d2898bb88cd84819 (patch)
tree5880e238b224aa7d0a9ace3e61f0372e9232b79b
parentc5fc8dc1c188d9cd1283aabb8848f975cac71d71 (diff)
downloadprosody-06b5c50c4e4751e54ca01175d2898bb88cd84819.tar.gz
prosody-06b5c50c4e4751e54ca01175d2898bb88cd84819.zip
mod_mam: Attach stanza-id to original stanza (fixes #917)
-rw-r--r--plugins/mod_mam/mod_mam.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_mam/mod_mam.lua b/plugins/mod_mam/mod_mam.lua
index 4235fd59..b40b8a9a 100644
--- a/plugins/mod_mam/mod_mam.lua
+++ b/plugins/mod_mam/mod_mam.lua
@@ -290,7 +290,7 @@ local function message_handler(event, c2s)
local ok = archive:append(store_user, nil, stanza, time_now(), with);
if ok then
local id = ok;
- stanza:tag("stanza-id", { xmlns = xmlns_st_id, by = store_user.."@"..host, id = id }):up();
+ event.stanza:tag("stanza-id", { xmlns = xmlns_st_id, by = store_user.."@"..host, id = id }):up();
if cleanup then cleanup[store_user] = true; end
module:fire_event("archive-message-added", { origin = origin, stanza = stanza, for_user = store_user, id = id });
end