mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-01-18 17:11:15 +08:00
use json instead of body when crafting the request
This commit is contained in:
parent
a268d0e283
commit
233c1e304d
@ -9,6 +9,5 @@ pub fn services(cfg: &mut web::ServiceConfig) {
|
|||||||
|
|
||||||
#[get("/health")]
|
#[get("/health")]
|
||||||
async fn get_health() -> Result<HttpResponse, ResponseError> {
|
async fn get_health() -> Result<HttpResponse, ResponseError> {
|
||||||
let payload = serde_json::json!({ "status": "available" });
|
Ok(HttpResponse::Ok().json(serde_json::json!({ "status": "available" })))
|
||||||
Ok(HttpResponse::Ok().body(payload.to_string()))
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user