From eb1cfdbab059ac3943630a954cc8d7ce6a1387b8 Mon Sep 17 00:00:00 2001 From: Philip Beelmann Date: Thu, 27 Apr 2023 10:06:28 +0000 Subject: [PATCH] bugfixes: copy/paste + renaming --- umap/static/umap/js/umap.features.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/umap/static/umap/js/umap.features.js b/umap/static/umap/js/umap.features.js index e7f01e35..c872e689 100644 --- a/umap/static/umap/js/umap.features.js +++ b/umap/static/umap/js/umap.features.js @@ -854,8 +854,8 @@ L.U.Polyline = L.Polyline.extend({ }, getMeasure: function (shape) { - var measure = L.GeoUtil.lineLength(this.map, shape || this._defaultShape()); - return L.GeoUtil.readableDistance(measure, this.map.measureTools.getMeasureUnit()); + var length = L.GeoUtil.lineLength(this.map, shape || this._defaultShape()); + return L.GeoUtil.readableDistance(length, this.map.measureTools.getMeasureUnit()); }, getContextMenuEditItems: function (e) { @@ -1005,8 +1005,8 @@ L.U.Polygon = L.Polygon.extend({ }, getMeasure: function (shape) { - var measure = L.GeoUtil.lineLength(this.map, shape || this._defaultShape()); - return L.GeoUtil.readableArea(measure, this.map.measureTools.getMeasureUnit()); + var area = L.GeoUtil.geodesicArea(shape || this._defaultShape()); + return L.GeoUtil.readableArea(area, this.map.measureTools.getMeasureUnit()); }, getContextMenuEditItems: function (e) {