Skip to content

Commit 70924ef

Browse files
committed
update update collection method
1 parent 0ff356f commit 70924ef

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

stac_fastapi/opensearch/stac_fastapi/opensearch/database_logic.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -772,7 +772,6 @@ async def find_collection(self, collection_id: str) -> Collection:
772772

773773
return collection["_source"]
774774

775-
# this is copied from stac-fastapi-elasticseach and the logic needs to be updated for opensearch
776775
async def update_collection(
777776
self, collection_id: str, collection: Collection, refresh: bool = False
778777
):
@@ -816,7 +815,7 @@ async def update_collection(
816815
await self.client.index(
817816
index=COLLECTIONS_INDEX,
818817
id=collection_id,
819-
document=collection,
818+
body=collection,
820819
refresh=refresh,
821820
)
822821

0 commit comments

Comments
 (0)