Skip to content

Commit

Permalink
Use WKT Format object as toString no longer performs intended action …
Browse files Browse the repository at this point in the history
…for writing WKT of geom (#1192)
  • Loading branch information
alexgao1 authored Sep 26, 2023
1 parent a6df67a commit 728d3f3
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions nunaliit2-js/src/main/js/nunaliit2/n2.couchGeom.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,12 @@ function getCouchGeometry(geom, isNewOpenlayers) {
]
};
} else {
var bounds = geom.getExtent();
var wkt = geom.toString();
const wktFormat = new $n2.n2es6.ol_format_WKT()

return {
nunaliit_type: 'geometry'
,wkt : wkt
,bbox: bounds
,wkt : wktFormat.writeGeometry(geom)
,bbox: geom.getExtent()
}
}

Expand Down

0 comments on commit 728d3f3

Please sign in to comment.