aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/handler/DistanceHandler.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-05-30 13:12:37 -0700
committerAnton Tananaev <anton@traccar.org>2022-05-30 13:12:37 -0700
commitce661ec77a957b70c15509c6801e6f34b32ad11d (patch)
tree1fd501abc09e1eeceb3bf411b5d2612b27cc35ad /src/main/java/org/traccar/handler/DistanceHandler.java
parent154ff3b2175e67b3fac531cb9c5c5c68880f5e12 (diff)
downloadtrackermap-server-ce661ec77a957b70c15509c6801e6f34b32ad11d.tar.gz
trackermap-server-ce661ec77a957b70c15509c6801e6f34b32ad11d.tar.bz2
trackermap-server-ce661ec77a957b70c15509c6801e6f34b32ad11d.zip
Improve dependency injection
Diffstat (limited to 'src/main/java/org/traccar/handler/DistanceHandler.java')
-rw-r--r--src/main/java/org/traccar/handler/DistanceHandler.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/org/traccar/handler/DistanceHandler.java b/src/main/java/org/traccar/handler/DistanceHandler.java
index 1e7e444f6..08c8c068d 100644
--- a/src/main/java/org/traccar/handler/DistanceHandler.java
+++ b/src/main/java/org/traccar/handler/DistanceHandler.java
@@ -1,6 +1,6 @@
/*
+ * Copyright 2016 - 2022 Anton Tananaev (anton@traccar.org)
* Copyright 2015 Amila Silva
- * Copyright 2016 - 2021 Anton Tananaev (anton@traccar.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -24,6 +24,7 @@ import org.traccar.database.IdentityManager;
import org.traccar.helper.DistanceCalculator;
import org.traccar.model.Position;
+import javax.inject.Inject;
import java.math.BigDecimal;
import java.math.RoundingMode;
@@ -36,6 +37,7 @@ public class DistanceHandler extends BaseDataHandler {
private final int coordinatesMinError;
private final int coordinatesMaxError;
+ @Inject
public DistanceHandler(Config config, IdentityManager identityManager) {
this.identityManager = identityManager;
this.filter = config.getBoolean(Keys.COORDINATES_FILTER);