mirror of
https://github.com/zulip/zulip.git
synced 2025-11-15 03:11:54 +00:00
muting: Replace muted_topics Dict with IntDict.
Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
This commit is contained in:
committed by
Tim Abbott
parent
e10da9c85f
commit
052497de1c
@@ -1,7 +1,7 @@
|
||||
const Dict = require('./dict').Dict;
|
||||
const FoldDict = require('./fold_dict').FoldDict;
|
||||
const IntDict = require('./int_dict').IntDict;
|
||||
|
||||
let muted_topics = new Dict();
|
||||
const muted_topics = new IntDict();
|
||||
|
||||
exports.add_muted_topic = function (stream_id, topic) {
|
||||
let sub_dict = muted_topics.get(stream_id);
|
||||
@@ -38,7 +38,7 @@ exports.get_muted_topics = function () {
|
||||
};
|
||||
|
||||
exports.set_muted_topics = function (tuples) {
|
||||
muted_topics = new Dict();
|
||||
muted_topics.clear();
|
||||
|
||||
_.each(tuples, function (tuple) {
|
||||
const stream_name = tuple[0];
|
||||
|
||||
Reference in New Issue
Block a user