diff --git a/WebApp/src/uk/ac/exeter/QuinCe/data/Dataset/DatasetSensorValues.java b/WebApp/src/uk/ac/exeter/QuinCe/data/Dataset/DatasetSensorValues.java index 4ea5935aa..fd5ff50d8 100644 --- a/WebApp/src/uk/ac/exeter/QuinCe/data/Dataset/DatasetSensorValues.java +++ b/WebApp/src/uk/ac/exeter/QuinCe/data/Dataset/DatasetSensorValues.java @@ -168,9 +168,9 @@ public boolean contains(SensorValue sensorValue) { public boolean contains(LocalDateTime time) { boolean result = false; - result = longitudes.containsTime(time); + result = null != longitudes && longitudes.containsTime(time); if (!result) { - result = latitudes.containsTime(time); + result = null != latitudes && latitudes.containsTime(time); } if (!result) { for (SensorValuesList sensorValues : valuesByColumn.values()) {