aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/geofence/GeofencePolyline.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/geofence/GeofencePolyline.java')
-rw-r--r--src/org/traccar/geofence/GeofencePolyline.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/org/traccar/geofence/GeofencePolyline.java b/src/org/traccar/geofence/GeofencePolyline.java
index e99987207..cadc69da6 100644
--- a/src/org/traccar/geofence/GeofencePolyline.java
+++ b/src/org/traccar/geofence/GeofencePolyline.java
@@ -38,7 +38,7 @@ public class GeofencePolyline extends GeofenceGeometry {
public boolean containsPoint(double latitude, double longitude) {
double longitude360 = longitude + Coordinate.DEGREE360;
for (int i = 1; i < coordinates.size(); i++) {
- if (DistanceCalculator.distanceToInterval(
+ if (DistanceCalculator.distanceToLine(
latitude, longitude360, coordinates.get(i - 1).getLat(), coordinates.get(i - 1).getLon360(),
coordinates.get(i).getLat(), coordinates.get(i).getLon360()) <= distance) {
return true;