Ignore:
Timestamp:
2020-09-28T15:25:56+02:00 (4 years ago)
Author:
GerdP
Message:

fix #19856: DataIntegrityProblemException: Primitive must be part of the dataset

  • make sure that global fields are properly initialized
File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/terracer/src/org/openstreetmap/josm/plugins/terracer/TerracerAction.java

    r35558 r35560  
    104104    @Override
    105105    public void actionPerformed(ActionEvent e) {
     106        cleanup();
    106107        Collection<OsmPrimitive> sel = getLayerManager().getEditDataSet().getSelected();
    107108        Way outline = null;
     
    220221            } catch (UserCancelException ex) {
    221222                Logging.trace(ex);
    222             } finally {
    223                 this.commands.clear();
    224                 this.commands = null;
    225223            }
    226224        } else {
     
    230228                    associatedStreet, housenumbers, title).dialog.showDialog();
    231229        }
     230        cleanup();
     231    }
     232
     233    private void cleanup() {
     234        commands = null;
     235        primitives = null;
     236        tagsInConflict = null;
    232237    }
    233238
Note: See TracChangeset for help on using the changeset viewer.