mirror of
https://github.com/zulip/zulip.git
synced 2025-11-04 14:03:30 +00:00
refactor: Move maybe_get_stream_name from stream_data to sub_store.
This commit moves `maybe_get_stream_name` function from `stream_data` to `sub_store` as it didn't had any dependency on `stream_data` and it also helps us to cut off dependency on `stream_data` for some of the modules including `user_topics`.
This commit is contained in:
@@ -11,13 +11,14 @@ import * as row from "./rows";
|
||||
import * as settings_data from "./settings_data";
|
||||
import * as stream_data from "./stream_data";
|
||||
import * as stream_settings_ui from "./stream_settings_ui";
|
||||
import * as sub_store from "./sub_store";
|
||||
|
||||
extend([lchPlugin, mixPlugin]);
|
||||
|
||||
export function update_stream_recipient_color($stream_header) {
|
||||
if ($stream_header.length) {
|
||||
const stream_id = Number.parseInt($($stream_header).attr("data-stream-id"), 10);
|
||||
const stream_name = stream_data.maybe_get_stream_name(stream_id);
|
||||
const stream_name = sub_store.maybe_get_stream_name(stream_id);
|
||||
if (!stream_name) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user