diff --git a/src/main/java/org/opentripplanner/middleware/triptracker/TripTrackingData.java b/src/main/java/org/opentripplanner/middleware/triptracker/TripTrackingData.java index 2e0d03abf..685cf0761 100644 --- a/src/main/java/org/opentripplanner/middleware/triptracker/TripTrackingData.java +++ b/src/main/java/org/opentripplanner/middleware/triptracker/TripTrackingData.java @@ -31,7 +31,9 @@ public class TripTrackingData { public TripTrackingData(MonitoredTrip trip, TrackedJourney journey, List locations) { this.trip = trip; this.journey = journey; - this.journey.trip = trip; + if (journey != null) { + this.journey.trip = trip; + } this.locations = locations; }