From 54d48825f34b1a211960b68c98a817eedcdbba9c Mon Sep 17 00:00:00 2001 From: Renaud Allard Date: Mon, 17 Oct 2016 23:54:53 +0200 Subject: Rework the circumvoluted logic in filter logging --- src/org/traccar/FilterHandler.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/org/traccar') diff --git a/src/org/traccar/FilterHandler.java b/src/org/traccar/FilterHandler.java index 725f9c429..f1df7ce2c 100644 --- a/src/org/traccar/FilterHandler.java +++ b/src/org/traccar/FilterHandler.java @@ -175,10 +175,14 @@ public class FilterHandler extends BaseDataHandler { filterType.append("Distance "); } - if (!"".equals(filterType.toString()) && !filterLimit(p)) { + if (filterType.length() > 0) { result = true; } + if (filterLimit(p)) { + result = false; + } + if (result) { Log.info("Position filtered by " + filterType.toString() + "filters from " + p.getDeviceId()); } -- cgit v1.2.3