Ticket #8480: validate-village-addrs.patch

File validate-village-addrs.patch, 1.4 KB (added by balrog-kun, 11 years ago)

Proposed fix

  • src/org/openstreetmap/josm/data/validation/tests/Addresses.java

    diff --git a/src/org/openstreetmap/josm/data/validation/tests/Addresses.java b/src/org/openstreetmap/josm/data/validation/tests/Addresses.java
    index 5b9a350..c10cff7 100644
    a b public class Addresses extends Test {  
    4444    protected static final String ADDR_INTERPOLATION = "addr:interpolation";
    4545    protected static final String ADDR_STREET        = "addr:street";
    4646    protected static final String ASSOCIATED_STREET  = "associatedStreet";
     47    protected static final String ADDR_PLACE         = "addr:place";
    4748   
    4849    protected class AddressError extends TestError {
    4950
    public class Addresses extends Test {  
    8485    @Override
    8586    public void visit(Node n) {
    8687        List<Relation> associatedStreets = getAndCheckAssociatedStreets(n);
    87         // Find house number without street (neither addr:street or associatedStreet)
    88         if (n.hasKey(ADDR_HOUSE_NUMBER) && !n.hasKey(ADDR_STREET)) {
     88        // Find house number without street (neither addr:street, associatedStreet or addr:place)
     89        if (n.hasKey(ADDR_HOUSE_NUMBER) && !n.hasKey(ADDR_STREET) && !n.hasKey(ADDR_PLACE)) {
    8990            for (Relation r : associatedStreets) {
    9091                if (r.hasTag("type", ASSOCIATED_STREET)) {
    9192                    return;