Skip to content

Commit 9d31f8b

Browse files
committed
refactor: Simplified code
1 parent f41cc65 commit 9d31f8b

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

src/main/java/org/opentripplanner/openstreetmap/tagmapping/HamburgMapper.java

+1-12
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,6 @@ public boolean isGeneralNoThroughTraffic(OSMWithTags way) {
1616
String access = way.getTag("access");
1717
boolean isNoThroughTraffic = doesTagValueDisallowThroughTraffic(access);
1818

19-
if (isNoThroughTraffic && way.hasTag("customers")) {
20-
String customers = way.getTag("customers");
21-
return !isAllowedThroughTrafficForHVV(access, customers);
22-
}
23-
24-
return isNoThroughTraffic;
25-
}
26-
27-
private boolean isAllowedThroughTrafficForHVV(String access, String customers) {
28-
boolean isAccessCustomers = "customers".equals(access);
29-
boolean isHVV = "HVV".equals(customers);
30-
return isAccessCustomers && isHVV;
19+
return isNoThroughTraffic && !way.isTag("customers", "HVV");
3120
}
3221
}

0 commit comments

Comments
 (0)