From 44e0a0073489058818aaa14efe6b7ed0e8571e2a Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Wed, 3 Nov 2021 16:52:32 -0600 Subject: [PATCH] Only show the first line of diagnostic messages in the status bar Co-Authored-By: Max Brunsfeld --- crates/workspace/src/items.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/workspace/src/items.rs b/crates/workspace/src/items.rs index 61e2d65986..9a14379c7a 100644 --- a/crates/workspace/src/items.rs +++ b/crates/workspace/src/items.rs @@ -300,7 +300,7 @@ impl View for DiagnosticMessage { ) .with_child( Label::new( - diagnostic.message.replace('\n', " "), + diagnostic.message.lines().next().unwrap().to_string(), theme.diagnostic_message.clone(), ) .boxed(),