Skip to content

Commit 5922020

Browse files
committed
fix: use the most probable geometry from geodini results
1 parent e73c1ee commit 5922020

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

stac_search/agents/items_search.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,9 +211,9 @@ def get_polygon_from_geodini(location: str):
211211
"rank": True,
212212
},
213213
)
214-
results = response.json().get("results", [])
215-
if results:
216-
polygon = results[0].get("geometry")
214+
result = response.json().get("most_probable", None)
215+
if result:
216+
polygon = result.get("geometry")
217217
return polygon
218218
return None
219219

0 commit comments

Comments
 (0)