fix: layer manager bug and null safety fixes (#960)

This commit is contained in:
Pål Håland
2026-05-08 22:13:39 +02:00
committed by GitHub
parent 127b7a0745
commit a11a4cb3cb

View File

@@ -108,8 +108,8 @@ export class LayerManager {
const source = this.map.getSource(sourceId) as M.GeoJSONSource const source = this.map.getSource(sourceId) as M.GeoJSONSource
source.setData(s.data) source.setData(s.data)
this.layers[id] = layer
} }
this.layers[id] = layer
return; return;
} }
for (const [id, s] of Object.entries(layer.spec.sources)) { for (const [id, s] of Object.entries(layer.spec.sources)) {