diff --git a/li.strolch.service/src/main/java/li/strolch/execution/policy/ReservationExecution.java b/li.strolch.service/src/main/java/li/strolch/execution/policy/ReservationExecution.java index 88d3e48d4..59aa469ce 100644 --- a/li.strolch.service/src/main/java/li/strolch/execution/policy/ReservationExecution.java +++ b/li.strolch.service/src/main/java/li/strolch/execution/policy/ReservationExecution.java @@ -62,14 +62,16 @@ public class ReservationExecution extends DurationExecution { @Override public void toExecuted(Action action) { switch (action.getType()) { + case TYPE_RESERVE: + setReservation(tx(), action, true); + break; case TYPE_RELEASE: - - setReservation(tx(), action, action.getType().equals(TYPE_RESERVE)); - - default: - super.toExecuted(action); + setReservation(tx(), action, false); + break; } + + super.toExecuted(action); } public static boolean isReserved(StrolchTransaction tx, Action action) {