Skip to content

Commit 8ab1a67

Browse files
committed
Search: Fix filters not applied when a single message is in the account
1 parent 887ab71 commit 8ab1a67

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

crates/store/src/dispatch/search.rs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,8 @@ use std::cmp::Ordering;
2020
impl SearchStore {
2121
pub async fn query_account(&self, query: SearchQuery) -> trc::Result<Vec<u32>> {
2222
// Pre-filter by mask
23-
match query.mask.len().cmp(&1) {
24-
Ordering::Equal => {
25-
return Ok(vec![query.mask.min().unwrap()]);
26-
}
27-
Ordering::Less => {
28-
return Ok(vec![]);
29-
}
30-
Ordering::Greater => {}
23+
if query.mask.is_empty() {
24+
return Ok(vec![]);
3125
}
3226

3327
// If the store does not support FTS, use the internal FTS store

0 commit comments

Comments
 (0)