changeset 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 b5a110544fd4
children 1d1eadff331d
files mod_firewall/actions.lib.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
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 = [[