mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-12-23 21:20:24 +01:00
fix the returned error when asc desc fails to be parsed
This commit is contained in:
parent
fe9f380993
commit
78b0bce9a1
@ -156,7 +156,7 @@ impl FromStr for AscDesc {
|
||||
match text.rsplit_once(':') {
|
||||
Some((left, "asc")) => Ok(AscDesc::Asc(left.parse()?)),
|
||||
Some((left, "desc")) => Ok(AscDesc::Desc(left.parse()?)),
|
||||
_ => Err(UserError::InvalidRankingRuleName { name: text.to_string() }),
|
||||
_ => Err(UserError::InvalidAscDescSyntax { name: text.to_string() }),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user