From 038b2ece4c3376df9ad067c3d8512042c75346ce Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Fri, 22 Jul 2022 11:50:25 +0200 Subject: [PATCH] Fix script --- scripts/generateCache.ts | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/scripts/generateCache.ts b/scripts/generateCache.ts index ce791b1899..e1cb4415d5 100644 --- a/scripts/generateCache.ts +++ b/scripts/generateCache.ts @@ -10,7 +10,7 @@ import {AllKnownLayouts} from "../Customizations/AllKnownLayouts"; import RelationsTracker from "../Logic/Osm/RelationsTracker"; import * as OsmToGeoJson from "osmtogeojson"; import MetaTagging from "../Logic/MetaTagging"; -import {UIEventSource} from "../Logic/UIEventSource"; +import {ImmutableStore, UIEventSource} from "../Logic/UIEventSource"; import {TileRange, Tiles} from "../Models/TileRange"; import LayoutConfig from "../Models/ThemeConfig/LayoutConfig"; import ScriptUtils from "./ScriptUtils"; @@ -250,9 +250,10 @@ function sliceToTiles(allFeatures: FeatureSource, theme: LayoutConfig, relations } const filteredTile = new FilteringFeatureSource({ - locationControl: new UIEventSource(undefined), + locationControl: new ImmutableStore(undefined), allElements: undefined, - selectedElement: new UIEventSource(undefined) + selectedElement: new ImmutableStore(undefined), + globalFilters: new ImmutableStore([]) }, tileIndex, tile, @@ -323,9 +324,10 @@ function sliceToTiles(allFeatures: FeatureSource, theme: LayoutConfig, relations if (pointsOnlyLayers.indexOf(layer.id) >= 0) { const filtered = new FilteringFeatureSource({ - locationControl: new UIEventSource(undefined), + locationControl: new ImmutableStore(undefined), allElements: undefined, - selectedElement: new UIEventSource(undefined) + selectedElement: new ImmutableStore(undefined), + globalFilters: new ImmutableStore([]) }, Tiles.tile_index(0, 0, 0), source,