diff --git a/Logic/SimpleMetaTagger.ts b/Logic/SimpleMetaTagger.ts index f6c0b5359..df259b7e5 100644 --- a/Logic/SimpleMetaTagger.ts +++ b/Logic/SimpleMetaTagger.ts @@ -279,6 +279,7 @@ export default class SimpleMetaTagger { return true; // Our job is done, lets unregister! } catch (e) { console.warn("Error while parsing opening hours of ", tags.id, e); + delete tags._isOpen tags["_isOpen"] = "parse_error"; } diff --git a/Models/ThemeConfig/LayerConfig.ts b/Models/ThemeConfig/LayerConfig.ts index 28d8b13b4..9e21e82af 100644 --- a/Models/ThemeConfig/LayerConfig.ts +++ b/Models/ThemeConfig/LayerConfig.ts @@ -559,9 +559,15 @@ export default class LayerConfig { } if (iconOverlay.badge) { const badgeParts: BaseUIElement[] = []; - const partDefs = iconOverlay.then + const renderValue = iconOverlay + .then .GetRenderValue(tgs) - .txt.split(";") + + if(renderValue === undefined){ + continue; + } + + const partDefs = renderValue.txt.split(";") .filter((prt) => prt != ""); for (const badgePartStr of partDefs) { diff --git a/UI/DefaultGUI.ts b/UI/DefaultGUI.ts index da15f1b2a..5c7f1b9a6 100644 --- a/UI/DefaultGUI.ts +++ b/UI/DefaultGUI.ts @@ -139,6 +139,12 @@ export default class DefaultGUI { features: state.homeLocation, enablePopups: false, }) + + state.leafletMap.addCallbackAndRunD(_ => { + // Lets assume that all showDataLayers are initialized at this point + state.selectedElement.ping() + return true; + }) } diff --git a/UI/ShowDataLayer/ShowDataLayer.ts b/UI/ShowDataLayer/ShowDataLayer.ts index 245619a72..d50b6711f 100644 --- a/UI/ShowDataLayer/ShowDataLayer.ts +++ b/UI/ShowDataLayer/ShowDataLayer.ts @@ -146,7 +146,7 @@ export default class ShowDataLayer { try { this.geoLayer.addData(feat); } catch (e) { - console.error("Could not add ", feat, "to the geojson layer in leaflet") + console.error("Could not add ", feat, "to the geojson layer in leaflet due to", e, e.stack) } } diff --git a/assets/layers/home_location/home_location.json b/assets/layers/home_location/home_location.json index 787b5ea67..0bf07c75a 100644 --- a/assets/layers/home_location/home_location.json +++ b/assets/layers/home_location/home_location.json @@ -1,17 +1,17 @@ { - "id": "home_location", - "description": "Meta layer showing the home location of the user", - "minzoom": 0, - "source": { - "osmTags": "user:home=yes" - }, - "icon": { - "render": "circle:white;./assets/svg/home.svg" - }, - "iconSize": { - "render": "20,20,center" - }, - "color": { - "render": "#00f" - } + "id": "home_location", + "description": "Meta layer showing the home location of the user", + "minzoom": 0, + "source": { + "osmTags": "user:home=yes" + }, + "icon": { + "render": "circle:white;./assets/svg/home.svg" + }, + "iconSize": { + "render": "20,20,center" + }, + "color": { + "render": "#00f" + } } \ No newline at end of file