Changeset

2577:00cef058df8d

mod_firewall: TO/FROM ADMIN OF: Fix string quoting
author Matthew Wild <mwild1@gmail.com>
date Sat, 25 Feb 2017 16:53:45 +0000
parents 2576:95b79d515a65
children 2578:6dbd07f9a868
files mod_firewall/conditions.lib.lua
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mod_firewall/conditions.lib.lua	Sat Feb 25 15:48:20 2017 +0000
+++ b/mod_firewall/conditions.lib.lua	Sat Feb 25 16:53:45 2017 +0000
@@ -156,11 +156,11 @@
 end
 
 function condition_handlers.FROM_ADMIN_OF(host)
-	return ("is_admin(bare_from, %s)"):format(host ~= "*" and host or nil), { "is_admin", "bare_from" };
+	return ("is_admin(bare_from, %s)"):format(host ~= "*" and metaq(host) or nil), { "is_admin", "bare_from" };
 end
 
 function condition_handlers.TO_ADMIN_OF(host)
-	return ("is_admin(bare_to, %s)"):format(host ~= "*" and host or nil), { "is_admin", "bare_to" };
+	return ("is_admin(bare_to, %s)"):format(host ~= "*" and metaq(host) or nil), { "is_admin", "bare_to" };
 end
 
 function condition_handlers.FROM_ADMIN()