Remove useless Facet variant

This commit is contained in:
many 2021-11-03 16:10:35 +01:00
parent 30a094cbb2
commit 06e6eaa7b4
No known key found for this signature in database
GPG Key ID: 2CEF23B75189EACA
2 changed files with 1 additions and 4 deletions

View File

@ -63,7 +63,6 @@ pub enum Code {
MissingDocumentId,
InvalidDocumentId,
Facet,
Filter,
Sort,
@ -133,8 +132,6 @@ impl Code {
MissingDocumentId => ErrCode::invalid("missing_document_id", StatusCode::BAD_REQUEST),
InvalidDocumentId => ErrCode::invalid("invalid_document_id", StatusCode::BAD_REQUEST),
// error related to facets
Facet => ErrCode::invalid("invalid_facet", StatusCode::BAD_REQUEST),
// error related to filters
Filter => ErrCode::invalid("invalid_filter", StatusCode::BAD_REQUEST),
// error related to sorts

View File

@ -367,7 +367,7 @@ mod compat {
"invalid_request" => Code::InvalidRankingRule,
"max_fields_limit_exceeded" => Code::MaxFieldsLimitExceeded,
"missing_document_id" => Code::MissingDocumentId,
"invalid_facet" => Code::Facet,
"invalid_facet" => Code::Filter,
"invalid_filter" => Code::Filter,
"invalid_sort" => Code::Sort,
"bad_parameter" => Code::BadParameter,