@@ -276,15 +276,10 @@ impl Application {
277 match notification {
277 match notification {
278 Notification::PublishDiagnostics(params) => {
278 Notification::PublishDiagnostics(params) => {
279− let path = Some(params.uri.to_file_path().unwrap());
279+ let path = params.uri.to_file_path().unwrap();
280+ let doc = self.editor.document_by_path_mut(&path);
285− .find(|(_, doc)| doc.path() == path.as_ref());
287− if let Some((_, doc)) = doc {
282+ if let Some(doc) = doc {
288 let text = doc.text();
283 let text = doc.text();
290 let diagnostics = params
285 let diagnostics = params