Changeset 13326 in josm for trunk/src/org/openstreetmap


Ignore:
Timestamp:
2018-01-15T01:35:32+01:00 (7 years ago)
Author:
Don-vip
Message:

findbugs - NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/Main.java

    r13322 r13326  
    415415                || (newValue != null && oldValue != null && !Objects.equals(newValue.toCode(), oldValue.toCode()))) {
    416416            listeners.removeIf(x -> x.get() == null);
    417             listeners.forEach(x -> x.get().projectionChanged(oldValue, newValue));
     417            listeners.stream().map(WeakReference::get).filter(Objects::nonNull).forEach(x -> x.projectionChanged(oldValue, newValue));
    418418            if (newValue != null && oldBounds != null && main != null) {
    419419                main.restoreOldBounds(oldBounds);
Note: See TracChangeset for help on using the changeset viewer.