mirror of
https://github.com/zulip/zulip.git
synced 2026-06-27 21:01:32 +08:00
Uptil now, the `query_matches_string_in_order` function would respect the order of words in the query string when matching a source string. This meant that for query "two one", the source string "one two three" would not be matched. For more flexibility, a new function, `query_matches_string_in_any_order`, has been added., which returns true if each word in the query string matches the prefix of a distinct word in the source string, else it returns false. The algorithm for computing this is quadratic in terms of the source word count so can be a little expensive, but it is only currently used for searching topics in Recent Conversations, where the strings' length is limited by the max stream / topic name length allowed, so this should be performant enough for this use case. |
||
|---|---|---|
| .. | ||
| fenced_code.ts | ||
| internal_url.js.flow | ||
| internal_url.ts | ||
| poll_data.js.flow | ||
| poll_data.ts | ||
| resolved_topic.js.flow | ||
| resolved_topic.ts | ||
| typeahead.js.flow | ||
| typeahead.ts | ||
| typing_status.js.flow | ||
| typing_status.ts | ||