mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-07-27 08:41:00 +00:00
implement list indexes
This commit is contained in:
@ -21,7 +21,7 @@ pub fn services(cfg: &mut web::ServiceConfig) {
|
||||
|
||||
#[get("/indexes", wrap = "Authentication::Private")]
|
||||
async fn list_indexes(data: web::Data<Data>) -> Result<HttpResponse, ResponseError> {
|
||||
match data.list_indexes() {
|
||||
match data.list_indexes().await {
|
||||
Ok(indexes) => {
|
||||
let json = serde_json::to_string(&indexes).unwrap();
|
||||
Ok(HttpResponse::Ok().body(&json))
|
||||
|
Reference in New Issue
Block a user