eslint: Fix unicorn/no-array-callback-reference.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg
2021-01-22 17:36:54 -08:00
committed by Tim Abbott
parent 552f4e3d22
commit 6cd694b8e3
29 changed files with 89 additions and 93 deletions

View File

@@ -41,7 +41,9 @@ function maybe_add_narrowed_messages(messages, msg_list) {
// edited in between when they sent the message and when
// we hear back from the server and can echo the new
// message. Arguably, it's counterproductive complexity.
new_messages = new_messages.map(message_store.add_message_metadata);
new_messages = new_messages.map((message) =>
message_store.add_message_metadata(message),
);
message_util.add_new_messages(new_messages, msg_list);
unread_ops.process_visible();
@@ -61,7 +63,7 @@ function maybe_add_narrowed_messages(messages, msg_list) {
}
exports.insert_new_messages = function insert_new_messages(messages, sent_by_this_client) {
messages = messages.map(message_store.add_message_metadata);
messages = messages.map((message) => message_store.add_message_metadata(message));
unread.process_loaded_messages(messages);
huddle_data.process_loaded_messages(messages);