Comparison

plugins/mod_mam/mod_mam.lua @ 10741:27f1fcd85ccd

mod_mam: Prefer not archiving if no interesting payloads are found
author Kim Alvefur <zash@zash.se>
date Tue, 21 Apr 2020 19:41:43 +0200
parent 10740:08efb60faf67
child 10742:70b7c8f3d32d
comparison
equal deleted inserted replaced
10740:08efb60faf67 10741:27f1fcd85ccd
303 if stanza:get_child("x", "jabber:x:conference") 303 if stanza:get_child("x", "jabber:x:conference")
304 or stanza:find("{http://jabber.org/protocol/muc#user}x/invite") then 304 or stanza:find("{http://jabber.org/protocol/muc#user}x/invite") then
305 return true, "invite"; 305 return true, "invite";
306 end 306 end
307 307
308 return true, "default"; 308 -- The IM-NG thing to do here would be to return `not st_to_full`
309 -- One day ...
310 return false, "default";
309 end 311 end
310 312
311 -- Handle messages 313 -- Handle messages
312 local function message_handler(event, c2s) 314 local function message_handler(event, c2s)
313 local origin, stanza = event.origin, event.stanza; 315 local origin, stanza = event.origin, event.stanza;