Fix;Studio: don't crash when the configuration file is seen

This commit is contained in:
Pieter Vander Vennet 2024-02-10 23:31:37 +01:00
parent 04b1f9f50f
commit 6ac4b159c8

View file

@ -6,13 +6,13 @@
export let tags: UIEventSource<Record<string, any>>
export let tagKeys = tags.map(tgs => Object.keys(tgs))
export let layer: LayerConfig
export let layer: LayerConfig | undefined = undefined
/**
* The names (keys) of the calculated tags. Each will normally start with an underscore (but in rare cases not)
*/
let calculatedTags: string[] = []
for (const calculated of layer.calculatedTags ?? []) {
for (const calculated of layer?.calculatedTags ?? []) {
if(calculated){
continue
}