From ad6de6e2689f61aa27922215cf34c01fdb7d06aa Mon Sep 17 00:00:00 2001 From: Steve Howell Date: Mon, 14 May 2018 20:21:14 +0000 Subject: [PATCH] message_list: Remove unused delay_render option. --- static/js/message_list.js | 8 +++----- static/js/message_util.js | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/static/js/message_list.js b/static/js/message_list.js index 6e4d44a3bf..42ee677f55 100644 --- a/static/js/message_list.js +++ b/static/js/message_list.js @@ -65,7 +65,7 @@ exports.MessageList.prototype = { } if ((self === exports.narrowed) && !self.empty() && - (self.selected_id() === -1) && !opts.delay_render) { + (self.selected_id() === -1)) { // And also select the newly arrived message. self.select_id(self.selected_id(), {then_scroll: true, use_closest: true}); } @@ -267,12 +267,10 @@ exports.MessageList.prototype = { }, append_to_view: function (messages, opts) { - opts = _.extend({delay_render: false, messages_are_new: false}, opts); + opts = _.extend({messages_are_new: false}, opts); this.num_appends += 1; - if (!opts.delay_render) { - this.view.append(messages, opts.messages_are_new); - } + this.view.append(messages, opts.messages_are_new); }, remove_and_rerender: function MessageList_remove_and_rerender(messages) { diff --git a/static/js/message_util.js b/static/js/message_util.js index 6ff722e26d..97f3374660 100644 --- a/static/js/message_util.js +++ b/static/js/message_util.js @@ -13,7 +13,7 @@ exports.add_messages = function add_messages(messages, msg_list, opts) { return; } - opts = _.extend({messages_are_new: false, delay_render: false}, opts); + opts = _.extend({messages_are_new: false}, opts); loading.destroy_indicator($('#page_loading_indicator')); $('#first_run_message').remove();