fix(assets): declare mergedManagementZonesGeojson to prevent ReferenceError in unified view
This commit is contained in:
parent
3e35c98a46
commit
288921b4aa
1 changed files with 2 additions and 1 deletions
|
|
@ -53,6 +53,7 @@ var assetsLoadModes = {}; // thematic_code → null | 'always' | 'filter' |
|
|||
|
||||
// MapLibre sources
|
||||
var mergedLocationsGeojson = { type: 'FeatureCollection', features: [] };
|
||||
var mergedManagementZonesGeojson = { type: 'FeatureCollection', features: [] };
|
||||
var mergedAssetsGeojson = { type: 'FeatureCollection', features: [] };
|
||||
var currentFetchAbortController = null;
|
||||
var assetClickPopup = null;
|
||||
|
|
@ -2805,7 +2806,7 @@ function rebuildMapSources() {
|
|||
const locSrc = map.getSource('locations');
|
||||
const asstSrc = map.getSource('assets');
|
||||
const zoneSrc = map.getSource('management_zones');
|
||||
if (!locSrc || !asstSrc) return; // sources not yet added (before mapLoaded)
|
||||
if (!locSrc || !asstSrc || !zoneSrc) return; // sources not yet added (before mapLoaded)
|
||||
|
||||
mergedLocationsGeojson = {
|
||||
type: 'FeatureCollection',
|
||||
|
|
|
|||
Loading…
Reference in a new issue