mirror of
https://github.com/adelphes/android-dev-ext.git
synced 2025-12-23 01:48:18 +00:00
clear diagnostics when document is closed
This commit is contained in:
@@ -228,9 +228,10 @@ function getDocumentSettings(resource) {
|
|||||||
|
|
||||||
// Only keep settings for open documents
|
// Only keep settings for open documents
|
||||||
documents.onDidClose((e) => {
|
documents.onDidClose((e) => {
|
||||||
connection.console.log('doc closed');
|
connection.console.log(`doc closed ${e.document.uri}`);
|
||||||
parsed = null;
|
parsed = null;
|
||||||
documentSettings.delete(e.document.uri);
|
documentSettings.delete(e.document.uri);
|
||||||
|
connection.sendDiagnostics({ uri: e.document.uri, diagnostics: [] });
|
||||||
});
|
});
|
||||||
|
|
||||||
// The content of a text document has changed. This event is emitted
|
// The content of a text document has changed. This event is emitted
|
||||||
|
|||||||
Reference in New Issue
Block a user