diff --git a/meilisearch/src/search.rs b/meilisearch/src/search.rs index 7f8af5fd1..129137859 100644 --- a/meilisearch/src/search.rs +++ b/meilisearch/src/search.rs @@ -44,7 +44,7 @@ pub struct SearchQuery { pub hits_per_page: Option, #[deserr(error = DeserrError)] pub attributes_to_retrieve: Option>, - #[deserr(error = DeserrError)] + #[deserr(error = DeserrError)] pub attributes_to_crop: Option>, #[deserr(error = DeserrError, default = DEFAULT_CROP_LENGTH())] pub crop_length: usize, diff --git a/meilisearch/tests/search/errors.rs b/meilisearch/tests/search/errors.rs index 511e17eb5..d582a3672 100644 --- a/meilisearch/tests/search/errors.rs +++ b/meilisearch/tests/search/errors.rs @@ -384,7 +384,7 @@ async fn search_bad_matching_strategy() { snapshot!(code, @"400 Bad Request"); snapshot!(json_string!(response), @r###" { - "message": "Incorrect tag value at `.matchingStrategy`.", + "message": "Json deserialize error: unknown value `doggo`, expected one of `last`, `all` at `.matchingStrategy`.", "code": "invalid_search_matching_strategy", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#invalid-search-matching-strategy" @@ -395,7 +395,7 @@ async fn search_bad_matching_strategy() { snapshot!(code, @"400 Bad Request"); snapshot!(json_string!(response), @r###" { - "message": "Incorrect tag value at `.matchingStrategy`.", + "message": "Json deserialize error: unknown value `doggo`, expected one of `last`, `all` at `.matchingStrategy`.", "code": "invalid_search_matching_strategy", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#invalid-search-matching-strategy"