Diff

mod_mam_muc/mod_mam_muc.lua @ 3364:264eab9d501c

mod_mam_muc: Log to debug log whether a message is archived or not
author Kim Alvefur <zash@zash.se>
date Sun, 28 Oct 2018 19:01:12 +0100
parent 3036:f7ebf8fcd602
line wrap: on
line diff
--- a/mod_mam_muc/mod_mam_muc.lua	Fri Oct 26 20:07:16 2018 +0200
+++ b/mod_mam_muc/mod_mam_muc.lua	Sun Oct 28 19:01:12 2018 +0100
@@ -407,7 +407,11 @@
 	end
 
 	-- Policy check
-	if not archiving_enabled(self) then return end -- Don't log
+	if not archiving_enabled(self) then -- Don't log
+		module:log("debug", "Not archiving %s", stanza:top_tag());
+		return;
+	end
+	module:log("debug", "Archiving %s", stanza:top_tag());
 
 	-- And stash it
 	local with = stanza.name