Software /
code /
prosody-modules
Changeset
3986:9ec23a457f9a
mod_smacks: remove now unused code
author | tmolitor <thilo@eightysoft.de> |
---|---|
date | Tue, 21 Apr 2020 11:26:43 +0200 |
parents | 3985:c3e9caa29857 |
children | 3987:dddcf094af5c |
files | mod_smacks/mod_smacks.lua |
diffstat | 1 files changed, 2 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/mod_smacks/mod_smacks.lua Mon Apr 20 15:30:56 2020 +0200 +++ b/mod_smacks/mod_smacks.lua Tue Apr 21 11:26:43 2020 +0200 @@ -420,6 +420,8 @@ end -- don't send delivery errors for messages which will be delivered by mam later on +-- check if stanza was archived --> this will allow us to send back errors for stanzas not archived +-- because the user configured the server to do so ("no-archive"-setting for one special contact for example) local function get_stanza_id(stanza, by_jid) for tag in stanza:childtags("stanza-id", "urn:xmpp:sid:0") do if tag.attr.by == by_jid then @@ -453,15 +455,6 @@ end end); --- mark stanzas as archived --> this will allow us to send back errors for stanzas not archived --- because the user configured the server to do so ("no-archive"-setting for one special contact for example) -module:hook("archive-message-added", function(event) - local session, stanza, for_user, stanza_id = event.origin, event.stanza, event.for_user, event.id; - local log = session.log or module._log - log("debug", "Marking stanza as archived, archive_id: %s, stanza: %s", tostring(stanza_id), tostring(stanza:top_tag())); - stanza._was_archived = true; -end); - module:hook("pre-resource-unbind", function (event) local session, err = event.session, event.error; if session.smacks then