diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2016-06-24 21:38:32 +1200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-06-24 21:38:32 +1200 |
commit | 5b254b93fef12f39b0782bbc94d5f280e680900c (patch) | |
tree | c2296ba2461ffc7d33bebb034468e56a5511defc /src/org/traccar/BaseEventHandler.java | |
parent | 25e323de26718d349999873196bc5c3f5d70eaae (diff) | |
parent | 52e7002ed39c333884529c3a0e8b4c6d23f0115e (diff) | |
download | trackermap-server-5b254b93fef12f39b0782bbc94d5f280e680900c.tar.gz trackermap-server-5b254b93fef12f39b0782bbc94d5f280e680900c.tar.bz2 trackermap-server-5b254b93fef12f39b0782bbc94d5f280e680900c.zip |
Merge pull request #2044 from Abyss777/master
Possibility to disable event and geofences
Diffstat (limited to 'src/org/traccar/BaseEventHandler.java')
-rw-r--r-- | src/org/traccar/BaseEventHandler.java | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/org/traccar/BaseEventHandler.java b/src/org/traccar/BaseEventHandler.java index 1ae9d2c6d..82e78c6b3 100644 --- a/src/org/traccar/BaseEventHandler.java +++ b/src/org/traccar/BaseEventHandler.java @@ -26,10 +26,8 @@ public abstract class BaseEventHandler extends BaseDataHandler { protected Position handlePosition(Position position) { Collection<Event> events = analyzePosition(position); - if (events != null) { - for (Event event : events) { - Context.getNotificationManager().updateEvent(event, position); - } + if (events != null && Context.getNotificationManager() != null) { + Context.getNotificationManager().updateEvents(events, position); } return position; } |