on master help sign in
Display error code only if not none
commita43bcc876568b87f0e326612f5385d8c4922cb14 authorGokul Soumya <gokulps15@gmail.com> dateTue 5 Jul 2022, 17:54 (4 years ago) parent0c10468
1 file changed+2−3
helix-term/src/commands/lsp.rs+2−3
helix-term/src/commands/lsp.rs+2−3
@@ -125,6 +125,7 @@ impl ui::menu::Item for PickerDiagnostic {
125125 NumberOrString::Number(n) => n.to_string(),
126126 NumberOrString::String(s) => s.to_string(),
127127 })
128+ .map(|code| format!(" ({})", code))
128129 .unwrap_or_default();
129130
130131 let truncated_path = path::get_truncated_path(self.url.path())
@@ -135,9 +136,7 @@ impl ui::menu::Item for PickerDiagnostic {
135136 Span::raw(truncated_path),
136137 Span::raw(": "),
137138 Span::styled(&self.diag.message, style),
138− Span::raw(" ("),
139− Span::styled(code, style.add_modifier(Modifier::BOLD)),
140− Span::raw(")"),
139+ Span::styled(code, style),
141140 ])
142141 }
143142}