diff mod_firewall/actions.lib.lua @ 5865:bfc35ae9edcb

mod_firewall: 'REPORT TO': fix default reason fallback if none is provided
author Matthew Wild <mwild1@gmail.com>
date Tue, 12 Mar 2024 14:27:43 +0000
parents 1249ab2f797c
children 3f5644aa5c32
line wrap: on
line diff
--- a/mod_firewall/actions.lib.lua	Tue Mar 12 14:07:00 2024 +0000
+++ b/mod_firewall/actions.lib.lua	Tue Mar 12 14:27:43 2024 +0000
@@ -263,7 +263,7 @@
 	local where, reason, text = spec:match("^%s*(%S+) *(%S*) *(.*)$");
 	if reason == "spam" then
 		reason = "urn:xmpp:reporting:spam";
-	elseif reason == "abuse" or not reason then
+	elseif reason == "abuse" or not reason or reason = "" then
 		reason = "urn:xmpp:reporting:abuse";
 	end
 	local code = [[