kopia lustrzana https://github.com/JOSM/MapWithAI
Ensure that the counter for unique ids is only ever advanced once
This fixes JOSM-18601, if the analysis was correct. Signed-off-by: Taylor Smock <taylor.smock@kaart.com>pull/1/head
rodzic
582bf0c640
commit
68a81a1e4e
|
@ -36,7 +36,10 @@ public class BoundingBoxMapWithAIDownloader extends BoundingBoxDownloader {
|
|||
|
||||
@Override
|
||||
protected DataSet parseDataSet(InputStream source, ProgressMonitor progressMonitor) throws IllegalDataException {
|
||||
DataSet ds = OsmReaderCustom.parseDataSet(source, progressMonitor, true);
|
||||
DataSet ds;
|
||||
synchronized (BoundingBoxMapWithAIDownloader.class) {
|
||||
ds = OsmReaderCustom.parseDataSet(source, progressMonitor, true);
|
||||
}
|
||||
GetDataRunnable.addMapWithAISourceTag(ds, MapWithAIPreferenceHelper.getMapWithAIUrl().stream()
|
||||
.filter(map -> map.getOrDefault("url", "no-url").equals(url))
|
||||
.map(map -> map.getOrDefault("source", MapWithAIPlugin.NAME)).findFirst().orElse(MapWithAIPlugin.NAME));
|
||||
|
|
Ładowanie…
Reference in New Issue