diff --git a/CHANGELOG.md b/CHANGELOG.md index 70af1526..354b34e4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,9 +6,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.0.6] - -### Changed +### Fixed + +- `to_wkt`for GeometryManager. + +### Added - Add docstring thanks to @piclem. +- Token support thanks to @luisageo6. ## [0.0.5] - 2024-02-19 diff --git a/earthdaily/earthdatastore/cube_utils/geometry_manager.py b/earthdaily/earthdatastore/cube_utils/geometry_manager.py index 4f695982..d63ce9e3 100644 --- a/earthdaily/earthdatastore/cube_utils/geometry_manager.py +++ b/earthdaily/earthdatastore/cube_utils/geometry_manager.py @@ -15,8 +15,9 @@ def to_intersects(self, crs="EPSG:4326"): ][0]["geometry"] def to_wkt(self, crs="EPSG:4326"): - list(self._obj.to_crs(crs=crs).to_wkt()["geometry"]) - + wkts = list(self._obj.to_crs(crs=crs).to_wkt()["geometry"]) + return wkts[0] if len(wkts)==1 else wkts + def to_json(self, crs="EPSG:4326"): return json.loads(self._obj.to_crs(crs=crs).to_json(drop_id=True))