diff --git a/src/Models/ThemeConfig/LayerConfig.ts b/src/Models/ThemeConfig/LayerConfig.ts index 19bfe641ad..e4f535cca8 100644 --- a/src/Models/ThemeConfig/LayerConfig.ts +++ b/src/Models/ThemeConfig/LayerConfig.ts @@ -83,6 +83,9 @@ export default class LayerConfig extends WithContextLoader { this.syncSelection = json.syncSelection ?? "no" if(!json.source){ + if(json.presets === undefined){ + throw "Error while parsing "+json.id+" in "+context+"; no source given" + } this.source = new SourceConfig({ osmTags: TagUtils.Tag({or: json.presets.map(pr => ({and:pr.tags}))}) })