Ignore:
Timestamp:
2010-10-31T15:27:32+01:00 (14 years ago)
Author:
oliverw
Message:

Bugfix: Addresses were not resolved corectly.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/AddressEditContainer.java

    r23961 r23965  
    359359                String streetName = aNode.getStreet();
    360360               
    361                 if (streetName != null && streetDict.containsKey(streetName)) {
    362                         StreetNode sNode = streetDict.get(streetName);
     361                if (streetName != null && shadowStreetDict.containsKey(streetName)) {
     362                        StreetNode sNode = shadowStreetDict.get(streetName);
    363363                        sNode.addAddress(aNode);
    364364                        return true;
     
    373373        public void resolveAddresses() {
    374374                List<AddressNode> resolvedAddresses = new ArrayList<AddressNode>();
    375                 for (AddressNode node : unresolvedAddresses) {
     375                for (AddressNode node : shadowUnresolvedAddresses) {
    376376                        if (assignAddressToStreet(node)) {
    377377                                resolvedAddresses.add(node);
     
    381381                /* Remove all resolves nodes from unresolved list */
    382382                for (AddressNode resolved : resolvedAddresses) {
    383                         unresolvedAddresses.remove(resolved);
     383                        shadowUnresolvedAddresses.remove(resolved);
    384384                }
    385385        }
     
    405405                        // sort lists
    406406                        Collections.sort(shadowIncompleteAddresses);
    407                         Collections.sort(shadowIncompleteAddresses);
     407                        Collections.sort(shadowUnresolvedAddresses);
    408408
    409409                        // put results from shadow copy into real lists
Note: See TracChangeset for help on using the changeset viewer.