changeset 4662:a357c3e3bd32

mod_spam_reporting: Fallback string for missing 'reason' Already done in that other module but forgot to do it here.
author Kim Alvefur <zash@zash.se>
date Wed, 25 Aug 2021 19:42:28 +0200
parents e40ed7d93d68
children 6e5572fc6840
files mod_spam_reporting/mod_spam_reporting.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mod_spam_reporting/mod_spam_reporting.lua	Wed Aug 25 19:33:59 2021 +0200
+++ b/mod_spam_reporting/mod_spam_reporting.lua	Wed Aug 25 19:42:28 2021 +0200
@@ -33,7 +33,7 @@
 			end
 
 			if report_type then
-				module:log("warn", "Received report of %s from JID '%s', %s", report_type, jid, reason);
+				module:log("warn", "Received report of %s from JID '%s', %s", report_type, jid, reason or "no reason given");
 				module:fire_event(module.name.."/"..report_type.."-report", {
 					origin = event.origin, stanza = event.stanza, jid = jid,
 					item = item, report = report, reason = reason, });