Skip to content

Commit

Permalink
close: #233
Browse files Browse the repository at this point in the history
  • Loading branch information
Raruto committed Apr 25, 2023
1 parent 8f7623c commit 2712268
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion libs/leaflet-hotline.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ https://github.com/iosphere/Leaflet.hotline/
1.0: 'red'
};

this._canvas = canvas = typeof canvas === 'string'
this._canvas = canvas = ('string' === typeof canvas)
? document.getElementById(canvas)
: canvas;

Expand Down
1 change: 1 addition & 0 deletions src/control.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ export const Elevation = L.Control.Elevation = L.Control.extend({
if (this._layers) this._clearLayers(this._layers);
if (this._markers) this._clearLayers(this._markers);
if (this._circleMarkers) this._circleMarkers.remove();
if (this._hotline) this._hotline.eachLayer(l => l.options.renderer.remove()); // hotfix for: https://github.com/Raruto/leaflet-elevation/issues/233
if (this._hotline) this._clearLayers(this._hotline);

this._data = [];
Expand Down

0 comments on commit 2712268

Please sign in to comment.