aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-12-07 09:55:54 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2015-12-07 09:55:54 +1300
commit33b2a5c9ab70ffe7bbdd074ce430920d2a0d3941 (patch)
treee1047e26004757cb580291bd7a02c968e20ffd69
parent617df639c1835b1710115403efe180c8f1804f02 (diff)
downloadtrackermap-server-33b2a5c9ab70ffe7bbdd074ce430920d2a0d3941.tar.gz
trackermap-server-33b2a5c9ab70ffe7bbdd074ce430920d2a0d3941.tar.bz2
trackermap-server-33b2a5c9ab70ffe7bbdd074ce430920d2a0d3941.zip
Fix compilation error in data manager
-rw-r--r--src/org/traccar/database/DataManager.java8
-rw-r--r--src/org/traccar/database/IdentityManager.java2
2 files changed, 7 insertions, 3 deletions
diff --git a/src/org/traccar/database/DataManager.java b/src/org/traccar/database/DataManager.java
index deb31094e..66d94ac91 100644
--- a/src/org/traccar/database/DataManager.java
+++ b/src/org/traccar/database/DataManager.java
@@ -124,8 +124,12 @@ public class DataManager implements IdentityManager {
}
@Override
- public Device getDeviceById(long id) throws SQLException {
- updateDeviceCache(!devicesById.containsKey(id));
+ public Device getDeviceById(long id) {
+ try {
+ updateDeviceCache(!devicesById.containsKey(id));
+ } catch (SQLException e) {
+ Log.warning(e);
+ }
return devicesById.get(id);
}
diff --git a/src/org/traccar/database/IdentityManager.java b/src/org/traccar/database/IdentityManager.java
index 761219dd5..8bdce09a3 100644
--- a/src/org/traccar/database/IdentityManager.java
+++ b/src/org/traccar/database/IdentityManager.java
@@ -19,7 +19,7 @@ import org.traccar.model.Device;
public interface IdentityManager {
- Device getDeviceById(long id) throws Exception;
+ Device getDeviceById(long id);
Device getDeviceByUniqueId(String uniqueId) throws Exception;