recent_topics: Handle mute/unmute update to topic.

* We don't remove topic data when it's muted. We will filter it
before rendering.
This commit is contained in:
Aman Agrawal
2020-05-15 17:57:36 +05:30
committed by Tim Abbott
parent 76b0c6de86
commit 04cdc89681
3 changed files with 24 additions and 0 deletions

View File

@@ -112,6 +112,7 @@ exports.mute = function (stream_id, topic) {
title_text: i18n.t("Topic muted"),
undo_button_text: i18n.t("Unmute"),
});
recent_topics.update_topic_is_muted(stream_id, topic, true);
};
exports.unmute = function (stream_id, topic) {
@@ -124,6 +125,7 @@ exports.unmute = function (stream_id, topic) {
exports.rerender();
exports.persist_unmute(stream_id, topic);
feedback_widget.dismiss();
recent_topics.update_topic_is_muted(stream_id, topic, false);
};
exports.toggle_mute = function (message) {