mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-04 12:27:13 +02:00
implement update index
This commit is contained in:
parent
77d5dd452f
commit
c4846dafca
6 changed files with 75 additions and 15 deletions
|
@ -95,7 +95,7 @@ async fn update_index(
|
|||
path: web::Path<IndexParam>,
|
||||
body: web::Json<UpdateIndexRequest>,
|
||||
) -> Result<HttpResponse, ResponseError> {
|
||||
match data.update_index(&path.index_uid, body.primary_key.as_ref(), body.name.as_ref()) {
|
||||
match data.update_index(&path.index_uid, body.primary_key.as_ref(), body.name.as_ref()).await {
|
||||
Ok(meta) => {
|
||||
let json = serde_json::to_string(&meta).unwrap();
|
||||
Ok(HttpResponse::Ok().body(json))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue