Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
channel chat: Set first loaded message ID when sending a message (#10034)
Bennet Bo Fenner27165e992710
diff --git a/crates/channel/src/channel_chat.rs b/crates/channel/src/channel_chat.rsindex 9085cebfa36..e662e2db8e2 100644--- a/crates/channel/src/channel_chat.rs+++ b/crates/channel/src/channel_chat.rs@@ -222,6 +222,9 @@ impl ChannelChat {let message = ChannelMessage::from_proto(response, &user_store, &mut cx).await?;this.update(&mut cx, |this, cx| {this.insert_messages(SumTree::from_item(message, &()), cx);+ if this.first_loaded_message_id.is_none() {+ this.first_loaded_message_id = Some(id);+ }})?;Ok(id)}))