From 406b710c27128eaaa90bc919f66d48b6f7281cfa Mon Sep 17 00:00:00 2001 From: Paul Heinrich Date: Thu, 4 Apr 2024 17:41:34 +0200 Subject: [PATCH] small changes for readability --- .../vsp/simpleParkingCostHandler/ParkingCostHandler.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/contribs/vsp/src/main/java/playground/vsp/simpleParkingCostHandler/ParkingCostHandler.java b/contribs/vsp/src/main/java/playground/vsp/simpleParkingCostHandler/ParkingCostHandler.java index c05dadf428e..a32d1f761eb 100644 --- a/contribs/vsp/src/main/java/playground/vsp/simpleParkingCostHandler/ParkingCostHandler.java +++ b/contribs/vsp/src/main/java/playground/vsp/simpleParkingCostHandler/ParkingCostHandler.java @@ -52,7 +52,6 @@ final class ParkingCostHandler implements TransitDriverStartsEventHandler, Activ private final Map, Double> personId2lastLeaveVehicleTime = new HashMap<>(); private final Map, String> personId2previousActivity = new HashMap<>(); private final Map, Id> personId2relevantModeLinkId = new HashMap<>(); - private final Map, Id> personId2homeLinkId = new HashMap<>(); private final Set> ptDrivers = new HashSet<>(); private final Set> hasAlreadyPaidDailyResidentialParkingCosts = new HashSet<>(); @@ -105,9 +104,10 @@ public void handleEvent(PersonDepartureEvent event) { @Override public void handleEvent(PersonLeavesVehicleEvent event) { - if (!ptDrivers.contains(event.getPersonId())) { - personId2lastLeaveVehicleTime.put(event.getPersonId(), event.getTime()); + if (ptDrivers.contains(event.getPersonId())) { + return; } + personId2lastLeaveVehicleTime.put(event.getPersonId(), event.getTime()); } @Override