Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

compose_reply: Add error handling when trying to fetch a message.

Maneesh Shukla2a91ed863112
diff --git a/web/src/compose_reply.ts b/web/src/compose_reply.ts
index 7cd5dad3ac0..9b944b47fcd 100644
--- a/web/src/compose_reply.ts
+++ b/web/src/compose_reply.ts
@@ -326,6 +326,15 @@ export function quote_message(opts: {
const data = z.object({raw_content: z.string()}).parse(raw_data);
replace_content(message, data.raw_content);
},
+ error() {
+ compose_ui.replace_syntax(
+ quoting_placeholder,
+ $t({defaultMessage: "[Error fetching message content.]"}),
+ $textarea,
+ opts.forward_message,
+ );
+ compose_ui.autosize_textarea($textarea);
+ },
});
}