# HG changeset patch # User Kim Alvefur # Date 1521911768 -3600 # Node ID cfcc78c509050a6810f14301e464074cd038863c # Parent f3bdb20214ab740856fd89dacddb713bd7e0d3d0 mod_muc_mam: Let muc/history.lib decide which messages to store diff -r f3bdb20214ab -r cfcc78c50905 plugins/mod_muc_mam.lua --- a/plugins/mod_muc_mam.lua Tue Dec 12 20:25:56 2017 +0100 +++ b/plugins/mod_muc_mam.lua Sat Mar 24 18:16:08 2018 +0100 @@ -334,11 +334,9 @@ end end -module:hook("muc-broadcast-message", function (event) +module:hook("muc-add-history", function (event) local room, stanza = event.room, event.stanza; - if stanza:get_child("body") then - save_to_history(room, stanza); - end + save_to_history(room, stanza); end); if module:get_option_boolean("muc_log_presences", true) then