mirror of https://github.com/zulip/zulip.git
0f7628280f
If cordelia searches on pm-with:iago@zulip.com,cordelia@zulip.com, we now properly treat that the same way as pm-with:iago@zulip.com. Before this fix, the query would initially go through the huddle code path. The symptom wasn't completely obvious, as eventually a deeper function would return a recipient id corresponding to a single PM with @iago@zulip.com, but we would only get messages where iago was the recipient, and not any messages where he was the sender to cordelia. I put the helper function for this in zerver/lib/addressee, which is somewhat speculative. Eventually, we'll want pm-with queries to allow for user ids, and I imagine there will be some shared logic with other Addressee code in terms of how we handle these strings. The way we deal with lists of emails/users for various endpoints is kind of haphazard in the current code, although granted it's mostly just repeating the same simple patterns. It would be nice for some of this code to converge a bit. This affects new messages, typing indicators, search filters, etc., and some endpoints have strange legacy stuff like supporting JSON-encoded lists, so it's not trivial to clean this up. Tweaked by tabbott to add some additional tests. |
||
---|---|---|
.. | ||
data_import | ||
lib | ||
management | ||
migrations | ||
openapi | ||
templatetags | ||
tests | ||
tornado | ||
views | ||
webhooks | ||
worker | ||
__init__.py | ||
apps.py | ||
context_processors.py | ||
decorator.py | ||
filters.py | ||
forms.py | ||
logging_handlers.py | ||
middleware.py | ||
models.py | ||
signals.py | ||
static_header.txt |