local echo: Bypass message.flags array.

We no longer set message.flags in the local echo path.

In the markdown parsing step, we just set message.mentioned
directly.

And then we change `insert_new_messages` to no longer
convert flags to booleans, and move that code to only
happen for incoming server message events.
This commit is contained in:
Steve Howell
2017-12-16 17:25:31 -05:00
committed by showell
parent 4d8d17d134
commit 0a3d769911
8 changed files with 81 additions and 32 deletions

View File

@@ -55,7 +55,6 @@ function maybe_add_narrowed_messages(messages, msg_list, messages_are_new) {
exports.insert_new_messages = function insert_new_messages(messages, locally_echoed) {
_.each(messages, message_store.set_message_booleans);
messages = _.map(messages, message_store.add_message_metadata);
unread.process_loaded_messages(messages);