Skip to content

Commit

Permalink
see #21319 - fix NPE
Browse files Browse the repository at this point in the history
git-svn-id: https://josm.openstreetmap.de/svn/trunk@18222 0c6e7542-c601-0410-84e7-c038aed88b3b
  • Loading branch information
don-vip committed Sep 12, 2021
1 parent 1229623 commit 558443b
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -452,8 +452,9 @@ public boolean ok() {

setProjection(id, prefs, false);

if (PROP_COORDINATES.put(((ICoordinateFormat) coordinatesCombo.getSelectedItem()).getId())) {
CoordinateFormatManager.setCoordinateFormat((ICoordinateFormat) coordinatesCombo.getSelectedItem());
ICoordinateFormat selectedItem = (ICoordinateFormat) coordinatesCombo.getSelectedItem();
if (selectedItem != null && PROP_COORDINATES.put(selectedItem.getId())) {
CoordinateFormatManager.setCoordinateFormat(selectedItem);
}

SystemOfMeasurement.setSystemOfMeasurement(((SystemOfMeasurement) unitsCombo.getSelectedItem()));
Expand Down

0 comments on commit 558443b

Please sign in to comment.