diff --git a/src/CategoryOverpass.js b/src/CategoryOverpass.js index 13b03457..f849148a 100644 --- a/src/CategoryOverpass.js +++ b/src/CategoryOverpass.js @@ -249,10 +249,9 @@ CategoryOverpass.prototype.open = function () { if (!this.lists) { this.lists = [] + this.listsDom = [] if (this.data.lists) { - this.listsDom = [] - let wrapper = document.createElement('div') wrapper.className = 'categoryWrapper' this.domContent.appendChild(wrapper) @@ -311,6 +310,7 @@ CategoryOverpass.prototype.open = function () { let list = new OverpassLayerList(this.layer, {}) this.lists.push(list) list.addTo(this.domContent) + this.listsDom.push(this.domContent) showMore(this, this.domContent) }