From e3a75b43e5d59de7bccc1795757f648c5598ff8a Mon Sep 17 00:00:00 2001 From: Andrew Lewis Date: Fri, 9 Sep 2016 14:23:57 +0200 Subject: [Minor] Mostly disable Hfilter for local networks as well --- src/plugins/lua/hfilter.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/plugins/lua/hfilter.lua b/src/plugins/lua/hfilter.lua index 34a679641..c1d0e22b2 100644 --- a/src/plugins/lua/hfilter.lua +++ b/src/plugins/lua/hfilter.lua @@ -294,14 +294,14 @@ local function hfilter(task) end end - --No more checks for auth user - if task:get_user() ~= nil then + --No more checks for auth user or local network + local rip = task:get_from_ip() + if task:get_user() or (rip and rip:is_local()) then return false end --local message = task:get_message() local ip = false - local rip = task:get_from_ip() if rip and rip:is_valid() then ip = rip:to_string() end -- cgit v1.2.3