Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
refactor: Rename MessageList.update_muting_and_rerender.
Abhijeet Prasad Bodas3a9dfc02e641
diff --git a/static/js/message_events.js b/static/js/message_events.jsindex 51d5b70fb49..1e686c1b74b 100644--- a/static/js/message_events.js+++ b/static/js/message_events.js@@ -401,11 +401,11 @@ export function update_messages(events) {// propagated edits to be updated (since the topic edits can have// changed the correct grouping of messages).if (topic_edited || stream_changed) {- message_lists.home.update_muting_and_rerender();+ message_lists.home.update_topic_muting_and_rerender();// However, we don't need to rerender message_list.narrowed if// we just changed the narrow earlier in this function.if (!changed_narrow && message_lists.current === message_list.narrowed) {- message_list.narrowed.update_muting_and_rerender();+ message_list.narrowed.update_topic_muting_and_rerender();}} else {// If the content of the message was edited, we do a special animation.diff --git a/static/js/message_list.js b/static/js/message_list.jsindex 7e41b722399..db9461e53a0 100644--- a/static/js/message_list.js+++ b/static/js/message_list.js@@ -379,12 +379,11 @@ export class MessageList {}}- update_muting_and_rerender() {- if (!this.excludes_muted_topics) {- return;+ update_topic_muting_and_rerender() {+ if (this.excludes_muted_topics) {+ this.data.update_items_for_muting();+ this.rerender();}- this.data.update_items_for_muting();- this.rerender();}all_messages() {diff --git a/static/js/muting_ui.js b/static/js/muting_ui.jsindex 5ec8934f055..e6038d73e5b 100644--- a/static/js/muting_ui.js+++ b/static/js/muting_ui.js@@ -32,11 +32,9 @@ export function rerender_on_topic_update() {stream_list.update_streams_sidebar();recent_topics.complete_rerender();- if (message_lists.current.excludes_muted_topics) {- message_lists.current.update_muting_and_rerender();- }+ message_lists.current.update_topic_muting_and_rerender();if (message_lists.current !== message_lists.home) {- message_lists.home.update_muting_and_rerender();+ message_lists.home.update_topic_muting_and_rerender();}if (overlays.settings_open() && settings_muting.loaded) {set_up_muted_topics_ui();