Fixed bug with same item can be added to avoid roads twice

This commit is contained in:
Denis 2014-11-19 14:58:16 +02:00
parent 99e8409e37
commit 7d0916bce6

View file

@ -114,8 +114,10 @@ public class RoutingConfiguration {
}
public void addImpassableRoad(RouteDataObject r) {
impassableRoadIds.add(r.id);
impassableRoads.add(r);
if (!impassableRoadIds.contains(r.id)){
impassableRoadIds.add(r.id);
impassableRoads.add(r);
}
}