forked from MapComplete/MapComplete
Feature(statistics): add filter state to URL
This commit is contained in:
parent
99aa5403ca
commit
e66391fc03
2 changed files with 4 additions and 4 deletions
|
|
@ -81,7 +81,7 @@ export default class FilteredLayer {
|
|||
public static initLinkedState(
|
||||
layer: LayerConfig,
|
||||
context: string,
|
||||
osmConnection: OsmConnection,
|
||||
osmConnection?: OsmConnection,
|
||||
enabledByDefault?: Store<boolean>
|
||||
) {
|
||||
let isDisplayed: UIEventSource<boolean>
|
||||
|
|
@ -90,13 +90,13 @@ export default class FilteredLayer {
|
|||
context + "-layer-" + layer.id + "-enabled",
|
||||
layer.shownByDefault
|
||||
)
|
||||
} else if (layer.syncSelection === "theme-only") {
|
||||
} else if (layer.syncSelection === "theme-only" && osmConnection) {
|
||||
isDisplayed = FilteredLayer.getPref(
|
||||
osmConnection,
|
||||
context + "-layer-" + layer.id + "-enabled",
|
||||
layer
|
||||
)
|
||||
} else if (layer.syncSelection === "global") {
|
||||
} else if (layer.syncSelection === "global" && osmConnection) {
|
||||
isDisplayed = FilteredLayer.getPref(
|
||||
osmConnection,
|
||||
"layer-" + layer.id + "-enabled",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue