mod_auto_answer_disco_info/mod_auto_answer_disco_info.lua
changeset 3110 1fe7da46e915
parent 3085 e0ef90e96931
child 3272 4cdd1ddae72c
--- a/mod_auto_answer_disco_info/mod_auto_answer_disco_info.lua	Fri Jun 08 11:49:29 2018 +0200
+++ b/mod_auto_answer_disco_info/mod_auto_answer_disco_info.lua	Fri Jun 08 15:25:27 2018 +0200
@@ -23,7 +23,8 @@
 	if disco_info ~= nil and (node == nil or node == disco_info.attr.node) then
 		local iq = st.reply(stanza);
 		iq:add_child(st.clone(disco_info));
-		origin.log("debug", "Answering disco#info on the behalf of %s", to);
+		local log = origin.log or module._log;
+		log("debug", "Answering disco#info on the behalf of %s", to);
 		module:send(iq);
 		return true;
 	end