mirror of
https://github.com/zulip/zulip.git
synced 2025-11-05 22:43:42 +00:00
In the JS code, we now use `message.unread` universally as the indicator of whether a message is unread, rather than the `message.flags` array that gets passed down to us from the server. In particular, we use the unread flag for filtering when you search. A lot of this commit is just removing logic to add/remove "read" from `message.flags` and updating tests. We also explicitly set `message.unread` to `false` inside of `unread.mark_as_read()` and no longer have `unread.set_flag()`. (Some of the callers to `unread.set_flag` were also calling `unread.mark_as_read`, which was updating the `message` object, so now we just have `unread.mark_as_read` update the `message` object. And then unread_ops.mark_all_as_read() was already calling unread.declare_bankruptcy().)
13 KiB
13 KiB