diff options
author | Kim Alvefur <zash@zash.se> | 2021-08-31 11:25:23 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2021-08-31 11:25:23 +0200 |
commit | 2937b1672bd28c5c40c2a9a11599bdf9f7794ebf (patch) | |
tree | bc4aee5ccfbcf72e72a286d6668c3bf2596eb632 /plugins/mod_mam/mod_mam.lua | |
parent | 20de5f297e486febdf389c578a9d44189c3b8ca4 (diff) | |
download | prosody-2937b1672bd28c5c40c2a9a11599bdf9f7794ebf.tar.gz prosody-2937b1672bd28c5c40c2a9a11599bdf9f7794ebf.zip |
mod_mam: Explain behavior with absent mod_offline in a comment
Diffstat (limited to 'plugins/mod_mam/mod_mam.lua')
-rw-r--r-- | plugins/mod_mam/mod_mam.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/mod_mam/mod_mam.lua b/plugins/mod_mam/mod_mam.lua index 92d45411..671967c3 100644 --- a/plugins/mod_mam/mod_mam.lua +++ b/plugins/mod_mam/mod_mam.lua @@ -474,6 +474,10 @@ end module:hook("pre-message/bare", strip_stanza_id_after_other_events, -1); module:hook("pre-message/full", strip_stanza_id_after_other_events, -1); +-- Catch messages not stored by mod_offline and mark them as stored if they +-- have been archived. This would generally only happen if mod_offline is +-- disabled. Otherwise the message would generate a delivery failure report, +-- which would not be accurate because it has been archived. module:hook("message/offline/handle", function(event) local stanza = event.stanza; if stanza:get_child("stanza-id", xmlns_st_id) then |