From 906276ac3f1e5b76abbec3632357f9c8c7163b21 Mon Sep 17 00:00:00 2001 From: Abyss777 Date: Wed, 15 Jun 2016 16:27:49 +0500 Subject: Use variables --- src/org/traccar/database/DataManager.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/org/traccar/database/DataManager.java b/src/org/traccar/database/DataManager.java index a530399c7..860bf1b84 100644 --- a/src/org/traccar/database/DataManager.java +++ b/src/org/traccar/database/DataManager.java @@ -156,10 +156,9 @@ public class DataManager implements IdentityManager { devicesById.put(device.getId(), device); devicesByUniqueId.put(device.getUniqueId(), device); if (connectionManager != null && geofenceManager != null) { - Position lastPosition = Context.getConnectionManager().getLastPosition(device.getId()); + Position lastPosition = connectionManager.getLastPosition(device.getId()); if (lastPosition != null) { - device.setGeofenceIds(Context.getGeofenceManager() - .getCurrentDeviceGeofences(lastPosition)); + device.setGeofenceIds(geofenceManager.getCurrentDeviceGeofences(lastPosition)); } } } -- cgit v1.2.3