fix readable output for |-separated filters
This commit is contained in:
parent
bd6e92fa2d
commit
a91a93f0e2
@ -167,7 +167,7 @@ fn add_searchbox(res: &mut String, query: &Option<String>) -> std::fmt::Result {
|
||||
|
||||
fn compute_results(raw_query: String) -> AnyResult<PageData> {
|
||||
let mut body = String::with_capacity(10_000);
|
||||
let (raw_filters, query) = match parser::parse_filters(&raw_query.trim()) {
|
||||
let (raw_filters, query) = match parser::parse_filters(raw_query.trim()) {
|
||||
Ok(q) => q,
|
||||
Err(e) => {
|
||||
let s = format!("Could not parse query: {e:?}");
|
||||
|
@ -251,10 +251,7 @@ impl Display for Value {
|
||||
}
|
||||
Self::Numerical(n) => write!(f, "{n}"),
|
||||
Self::Multiple(m) => {
|
||||
for v in m {
|
||||
write!(f, "{v} or ")?
|
||||
}
|
||||
Ok(())
|
||||
write!(f, "one of [{}]", m.iter().map(Value::to_string).join(", "))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user