mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 21:13:36 +00:00
Allow negated has:* searches.
Before this change, we were incorrectly trying to do local filtering on negated has searches. (imported from commit d1a6f1feef6b3cc1c984eb91a73cd16c4e66874e)
This commit is contained in:
@@ -78,7 +78,15 @@ function assert_same_operators(result, terms) {
|
||||
];
|
||||
filter = new Filter(operators);
|
||||
assert(filter.has_operator('search'));
|
||||
assert(! filter.can_apply_locally());
|
||||
assert(!filter.can_apply_locally());
|
||||
|
||||
// Similar logic applies to negated "has" searches.
|
||||
operators = [
|
||||
{operator: 'has', operand: 'images', negated: true}
|
||||
];
|
||||
filter = new Filter(operators);
|
||||
assert(filter.has_operator('has'));
|
||||
assert(!filter.can_apply_locally());
|
||||
}());
|
||||
|
||||
(function test_new_style_operators() {
|
||||
|
||||
Reference in New Issue
Block a user