Fix overpass layer not selected on hash init

This commit is contained in:
Norbert Renner 2021-03-24 09:22:11 +01:00
parent 127f8e9e5b
commit 6a2da2064c

View file

@ -129,6 +129,11 @@
L.bind(function (obj, index, array) {
if (obj) {
layersControl.activateLayer(obj);
if (obj.layer instanceof OverpassLayer) {
// hack to select overlay (mark checked) in the layers control
// (OverpassLayer._layerAdd does not fire 'add' event)
layersControl._update();
}
if (obj && !obj.overlay) {
added = true;
}