DataHandler update
[staff/due1/sed-hs15-srs-purple.git] / src / main / java / ch / bfh / ti / srs / datahandler / DataHandlerForTests.java
index f8939da..f699888 100644 (file)
@@ -175,6 +175,9 @@ public class DataHandlerForTests implements DataHandler {
                                if (res.getId() == reservation.getId()){
                                        return false;
                                }
+                               else if(res.getResource() == reservation.getResource() && res.getDateRange().overlaps(reservation.getDateRange())){
+                                       return false;
+                               }
                        }
                        reservationList.add(reservation);
                        return true;