diff --git a/contribs/drt-extensions/src/main/java/org/matsim/contrib/drt/extension/preplanned/optimizer/PreplannedDrtOptimizer.java b/contribs/drt-extensions/src/main/java/org/matsim/contrib/drt/extension/preplanned/optimizer/PreplannedDrtOptimizer.java index fd0f6672826..5e47c385106 100644 --- a/contribs/drt-extensions/src/main/java/org/matsim/contrib/drt/extension/preplanned/optimizer/PreplannedDrtOptimizer.java +++ b/contribs/drt-extensions/src/main/java/org/matsim/contrib/drt/extension/preplanned/optimizer/PreplannedDrtOptimizer.java @@ -77,7 +77,7 @@ public PreplannedDrtOptimizer(DrtConfigGroup drtCfg, PreplannedSchedules preplan TravelTime travelTime, TravelDisutility travelDisutility, MobsimTimer timer, DrtTaskFactory taskFactory, EventsManager eventsManager, Fleet fleet, ScheduleTimingUpdater scheduleTimingUpdater) { Preconditions.checkArgument( - fleet.getVehicles().keySet().equals(preplannedSchedules.vehicleToPreplannedStops.keySet()), + fleet.getVehicles().keySet().containsAll(preplannedSchedules.vehicleToPreplannedStops.keySet()), "Some schedules are preplanned for vehicles outside the fleet"); this.mode = drtCfg.getMode();