Fix compilation errors

This commit is contained in:
Alex Dima 2021-11-08 09:58:13 +01:00
parent 84bdc31efe
commit f21d9494a2
No known key found for this signature in database
GPG key ID: 39563C1504FDD0C9
5 changed files with 8 additions and 8 deletions

View file

@ -40,10 +40,10 @@ export class DiagnosticsAdapter {
return;
}
let handle: any;
let handle: number;
this._listener[model.uri.toString()] = model.onDidChangeContent(() => {
clearTimeout(handle);
handle = setTimeout(() => this._doValidate(model.uri, modeId), 500);
handle = window.setTimeout(() => this._doValidate(model.uri, modeId), 500);
});
this._doValidate(model.uri, modeId);

View file

@ -21,7 +21,7 @@ export class WorkerManager {
constructor(defaults: LanguageServiceDefaults) {
this._defaults = defaults;
this._worker = null;
this._idleCheckInterval = setInterval(() => this._checkIfIdle(), 30 * 1000);
this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 30 * 1000);
this._lastUsedTime = 0;
this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
}