aboutsummaryrefslogtreecommitdiff
path: root/src/org
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2016-01-18 12:39:49 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2016-01-18 12:39:49 +1300
commit8220a4f928841b872649367c536876b7d8dc6143 (patch)
tree5ef5e2a6b51ff26537d61eafd6a5fd51cb8cd530 /src/org
parentae06bf5aee294905b52404220f4706534f93fc53 (diff)
downloadtrackermap-server-8220a4f928841b872649367c536876b7d8dc6143.tar.gz
trackermap-server-8220a4f928841b872649367c536876b7d8dc6143.tar.bz2
trackermap-server-8220a4f928841b872649367c536876b7d8dc6143.zip
Add flag to ignore unknown devices
Diffstat (limited to 'src/org')
-rw-r--r--src/org/traccar/database/DataManager.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/org/traccar/database/DataManager.java b/src/org/traccar/database/DataManager.java
index 094e1f419..73984952e 100644
--- a/src/org/traccar/database/DataManager.java
+++ b/src/org/traccar/database/DataManager.java
@@ -135,7 +135,8 @@ public class DataManager implements IdentityManager {
@Override
public Device getDeviceByUniqueId(String uniqueId) throws SQLException {
- updateDeviceCache(!devicesByUniqueId.containsKey(uniqueId));
+ updateDeviceCache(
+ !devicesByUniqueId.containsKey(uniqueId) && !config.getBoolean("database.ignoreUnknown"));
return devicesByUniqueId.get(uniqueId);
}