From 52e858a5886f8b147ea5b603e4f70f32e9bf82c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Renault?= Date: Thu, 20 Oct 2022 17:44:15 +0200 Subject: [PATCH] Reapply #2890 --- meilisearch-http/src/routes/tasks.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meilisearch-http/src/routes/tasks.rs b/meilisearch-http/src/routes/tasks.rs index e8eaa3a4f..23cfd53fe 100644 --- a/meilisearch-http/src/routes/tasks.rs +++ b/meilisearch-http/src/routes/tasks.rs @@ -414,7 +414,7 @@ async fn get_tasks( // We first transform a potential indexUid=* into a "not specified indexUid filter" // for every one of the filters: type, status, and indexUid. - let type_: Option> = kind.and_then(fold_star_or); + let kind: Option> = kind.and_then(fold_star_or); let uid: Option> = uid.map(|x| x.into_iter().collect()); let status: Option> = status.and_then(fold_star_or); let index_uid: Option> = index_uid.and_then(fold_star_or); @@ -423,7 +423,7 @@ async fn get_tasks( "Tasks Seen".to_string(), json!({ "filtered_by_index_uid": index_uid.as_ref().map_or(false, |v| !v.is_empty()), - "filtered_by_type": type_.as_ref().map_or(false, |v| !v.is_empty()), + "filtered_by_type": kind.as_ref().map_or(false, |v| !v.is_empty()), "filtered_by_status": status.as_ref().map_or(false, |v| !v.is_empty()), }), Some(&req), @@ -436,7 +436,7 @@ async fn get_tasks( limit: Some(limit), from, status, - kind: type_, + kind, index_uid, uid, before_enqueued_at,