Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
topic_link_util: Rename get_topic_link_content_with_stream_name.
Evy Kassirer0c4aa4468988
diff --git a/web/src/clipboard_handler.ts b/web/src/clipboard_handler.tsindex e8e4f571ef7..0cdfa1c3209 100644--- a/web/src/clipboard_handler.ts+++ b/web/src/clipboard_handler.ts@@ -39,7 +39,7 @@ export async function copy_link_to_clipboard(link: string): Promise<void> {} else {const stream = stream_data.get_sub_by_id(stream_topic_details.stream_id);assert(stream !== undefined);- const {text} = topic_link_util.get_topic_link_content(+ const {text} = topic_link_util.get_topic_link_content_with_stream_name(stream.name,stream_topic_details.topic_name,stream_topic_details.message_id,diff --git a/web/src/topic_link_util.ts b/web/src/topic_link_util.tsindex 831686a452b..7408512348f 100644--- a/web/src/topic_link_util.ts+++ b/web/src/topic_link_util.ts@@ -54,7 +54,7 @@ export function html_escape_markdown_syntax_characters(text: string): string {return text.replaceAll(invalid_stream_topic_regex, escape_invalid_stream_topic_characters);}-export function get_topic_link_content(+export function get_topic_link_content_with_stream_name(stream_name: string,topic_name?: string,message_id?: string,@@ -103,7 +103,11 @@ export function get_fallback_markdown_link(// Generates the vanilla markdown link syntax for a stream/topic/message link, as// a fallback for cases where the nicer Zulip link syntax would not// render properly due to special characters in the channel or topic name.- const {text, url} = get_topic_link_content(stream_name, topic_name, message_id);+ const {text, url} = get_topic_link_content_with_stream_name(+ stream_name,+ topic_name,+ message_id,+ );return as_markdown_link_syntax(text, url);}