forked from MapComplete/MapComplete
Auto-formatting
This commit is contained in:
parent
9e000d521f
commit
fed4cff878
26 changed files with 360 additions and 304 deletions
|
@ -210,8 +210,8 @@ export default class OverpassFeatureSource implements FeatureSource {
|
|||
if (overpass === undefined) {
|
||||
return undefined
|
||||
}
|
||||
this.runningQuery.setData(true);
|
||||
[data, date] = await overpass.queryGeoJson(bounds)
|
||||
this.runningQuery.setData(true)
|
||||
;[data, date] = await overpass.queryGeoJson(bounds)
|
||||
} catch (e) {
|
||||
self.retries.data++
|
||||
self.retries.ping()
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
/**
|
||||
* This actor will download the latest version of the selected element from OSM and update the tags if necessary.
|
||||
*/
|
||||
import {UIEventSource} from "../UIEventSource"
|
||||
import {ElementStorage} from "../ElementStorage"
|
||||
import {Changes} from "../Osm/Changes"
|
||||
import {OsmObject} from "../Osm/OsmObject"
|
||||
import {OsmConnection} from "../Osm/OsmConnection"
|
||||
import { UIEventSource } from "../UIEventSource"
|
||||
import { ElementStorage } from "../ElementStorage"
|
||||
import { Changes } from "../Osm/Changes"
|
||||
import { OsmObject } from "../Osm/OsmObject"
|
||||
import { OsmConnection } from "../Osm/OsmConnection"
|
||||
import LayoutConfig from "../../Models/ThemeConfig/LayoutConfig"
|
||||
import SimpleMetaTagger from "../SimpleMetaTagger"
|
||||
|
||||
|
@ -59,17 +59,16 @@ export default class SelectedElementTagsUpdater {
|
|||
return
|
||||
}
|
||||
try {
|
||||
|
||||
const latestTags = await OsmObject.DownloadPropertiesOf(id)
|
||||
if (latestTags === "deleted") {
|
||||
console.warn("The current selected element has been deleted upstream!")
|
||||
const currentTagsSource = state.allElements.getEventSourceById(id)
|
||||
if(currentTagsSource.data["_deleted"] === "yes"){
|
||||
if (currentTagsSource.data["_deleted"] === "yes") {
|
||||
return
|
||||
}
|
||||
currentTagsSource.data["_deleted"] = "yes"
|
||||
currentTagsSource.ping()
|
||||
return;
|
||||
return
|
||||
}
|
||||
SelectedElementTagsUpdater.applyUpdate(state, latestTags, id)
|
||||
console.log("Updated", id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue